-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SyntaxError: Unexpected token #11271
Comments
Hey @tezml! We really appreciate you taking the time to report an issue. The collaborators on this project attempt to help as many people as possible, but we're a limited number of volunteers, so it's possible this won't be addressed swiftly. If you need any help, or just have general Babel or JavaScript questions, we have a vibrant Slack community that typically always has someone willing to help. You can sign-up here for an invite." |
Where did you save your Babel config? |
this is my .babelrc |
In which directory is it saved? |
.babel save in my develop root directory |
Ok, we need to understand if the babel config is being loaded. Please try adding some invalid code to
Is it |
Before using babel 6.x has been no problem.So it's not a question of quotation.
Both of these are .babelrc |
In Babel 7, You can read more about it at https://babeljs.io/docs/en/config-files. You can either duplicate the file in both directories, or have a |
ok,I know.But this does not solve the problem |
Try using
"this" what? |
Noticed this issue too after bumping some No custom |
I have the same issue with all I have a custom babel file,
|
Could you share a small repository which reproduces the issue 🙏 |
@nicolo-ribaudo I don't have time at the moment, but I will attempt to in the next few days. |
Hey @nicolo-ribaudo just want to point out that, this was a false alarm in my case. Ended up being a bug in my build process. My .tsconfig file had So, completely unrelated to babel 💃 . Sorry I won't be able to help any further! Was just a coincidence it happened in the same commit/pull-request. |
@nicolo-ribaudo also a false alarm in my case. I let the issue sit for a while... did |
@tezml Please use the following combinations: {
"devDependencies": {
"@babel/core": "^7.9.0",
"@babel/preset-env": "^7.9.0",
"babel-loader": "^8.0.0",
}
}
I am gonna close this issue as we don't have reproduction repo. |
error code ↓↓↓↓
` ERROR in ../pc-react-next/src/index.js
Module build failed: SyntaxError: /Users/tezml/Desktop/pc-react-next/src/index.js: Unexpected token (362:9)
import ↓↓↓↓
The text was updated successfully, but these errors were encountered: