In the package.json file add "type" : "module", . Adding this enables ES6 modules. //This will enable you to use import statements without any errors