Unhandled JS Exception: Syntax Error
See original GitHub issueCouldn’t make it work on React Native.
{
"presets": [
"es2015",
"react-native",
"react-native-stage-0/decorator-support"
],
"plugins": [
"transform-es2015-parameters",
["extensible-destructuring", {"mode": "optout", "impl": "safe"}]
]
}
Issue Analytics
- State:
- Created 7 years ago
- Reactions:1
- Comments:9 (4 by maintainers)
Top Results From Across the Web
IOS - React Native - Unhandled JS Exception: SyntaxError
I have facing problem whenever I create a new React Native project. displayed red screen, and got following error message ...
Read more >[Solved]-IOS - React Native - Unhandled JS Exception: SyntaxError
So just start the tutorial again and use: react-native init AwesomeProject --version 0.38.0. This solved the problem for me. Have fun. Ayalon Grinfeld...
Read more >SyntaxError: missing ) after argument list - JavaScript | MDN
The JavaScript exception "missing ) after argument list" occurs when there is an error with how a function is called. This might be...
Read more >How to catch syntax errors in JavaScript? - Tutorialspoint
SyntaxError cannot be handled in js using try-catch blocks because they are thrown errors while the code is being parsed. To handle SyntaxError, ......
Read more >Errors | Node.js v19.3.0 Documentation
For all EventEmitter objects, if an 'error' event handler is not provided, the error will be thrown, causing the Node.js process to report...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I started getting this error again as of RN v0.43; I made a PR to improve debug messages: https://github.com/facebook/react-native/pull/13561. You can manually copy the changes there into your
node_modules/react-native
(at least until the PR is published in the next version) to get a better idea of what’s going wrong.For me,
module.exports
is being transformed strangely and the error reason isUnexpected keyword 'var'
. This occurs in several places, not just formoment-timezone
:Working bundled code using mode
optin
:Failing bundled code using mode
optout
:I’ll try to diagnose further, but for now I’m just continuing to use mode
optin
.Same error, I want to use immutable.js in my RN project .
RN version:0.38.0
I use mode
optout
, implimmutable
in .babelrc , then I start the RN project,Then I download the bundle file, and rename to
index.android.bundle?platform=android.js
, and runnode index.android.bundle?platform=android.js
@tomaskulich I only know a little about babel plugin, I use
babel-plugin-extensible-destructuring
in many production projects and these projects are all raect web projects, I really thank you for you work. Today it my first time try to use this plugin in RN project, does this plugin doesn’t work in RN project?