I'm following the React setup guide for setting up React for the first time. However, I've added async/await to my code. When the preprocessor - npx babel
runs, the output file looks like:
and the browser console is giving me the error:
Uncaught SyntaxError: Unexpected identifier
for the import.
I've checked that babel-runtime
is in my node-modules.
My package.json
dependencies looks like:
"dependencies": {
"babel-cli": "^6.26.0",
"babel-preset-react-app": "^3.1.2"
}