question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Syntax error: Unexpected token when trying asyncComponent

See original GitHub issue

Getting an error trying to run this…

image

create-react-app is up to date etc

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
EwertonFontescommented, Jun 22, 2017

When I updated react-scripts the problem change to this :

react-scripts: command not found!

So I executed this commands:

npm install -g npm@latest //(to update npm because it is sometimes buggy.) rm -rf node_modules //to remove the existing modules. npm install //to re-install the project dependencies.

And the problem was solved! Thanks very much @jayair !

0reactions
jayaircommented, Jun 22, 2017

@EwertonFontes Thanks for reporting back.

Read more comments on GitHub >

github_iconTop Results From Across the Web

SyntaxError: Unexpected token - JavaScript - MDN Web Docs
The JavaScript exceptions "unexpected token" occur when a specific language construct was expected, but something else was provided.
Read more >
vue-router : Failed to resolve async component default ...
Tried making this change but its not working and I reverted. const router = new VueRouter({ routes, // short for `routes: routes` //...
Read more >
Laravel Mix - unexpected token - Laracasts
I am trying to run this Vue.component( 'async-webpack-example', () => import('./my-async-component')l ) I get this error but thought mix could compile ...
Read more >
JavaScript Error Handling: Unexpected Token - GeeksforGeeks
An unexpected token occurs if JavaScript code has a missing or extra ... Unexpected token is similar to syntax error but more specific....
Read more >
Unexpected token error after adding await keyword to Node.js ...
Neil Lovelace : I keep getting this: This step was still trying to run code when the step ended. Make sure you await...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found