SyntaxError: Left hand side of operator '=' must be a reference.
Im running into SyntaxError: Left hand side of operator '=' must be a reference. when I initialize a new 0.17 project. In the Android avd emulator it specifies (line 2928 in the generated bundle) which is:
this._debugInfo[this._callbackID>>5]=null;
In the iOS emulator the error looks like:

I've tried uninstalling node_modules, restarting the packager, but no luck.
Hey madwed, thanks for reporting this issue!
React Native, as you've probably heard, is getting really popular and truth is we're getting a bit overwhelmed by the activity surrounding it. There are just too many issues for us to manage properly.
- If you don't know how to do something or something is not working as you expect but not sure it's a bug, please ask on StackOverflow with the tag
react-nativeor for more real time interactions, ask on Discord in the #react-native channel. - If this is a feature request or a bug that you would like to be fixed, please report it on Product Pains. It has a ranking feature that lets us focus on the most important issues the community is experiencing.
- We welcome clear issues and PRs that are ready for in-depth discussion. Please provide screenshots where appropriate and always mention the version of React Native you're using. Thank you for your contributions!
I am seeing the same issue for both a newly initialized project as well as for an existing (and working) project. In this case the Movie List Tutorial. Like @madwed I was using v0.17.0. I noticed there was a new react-native build released earlier today so I installed v0.18.0-rc in case there were inconsistencies with other react-native services. I was sure to run:
react-native upgrade
on both projects. There was nothing to upgrade on the newly init'ed project, but the schema was upgraded for the existing project.
conflict ios/HelloWorld.xcodeproj/xcshareddata/xcschemes/HelloWorld.xcscheme
? Overwrite ios/HelloWorld.xcodeproj/xcshareddata/xcschemes/HelloWorld.xcscheme? overwrite
force ios/HelloWorld.xcodeproj/xcshareddata/xcschemes/HelloWorld.xcscheme
This did not fix my issue. I am running a stock Nexus 5 emulator with Marshmallow and an iPhone 5s emulator. I will try to push to a device to see if the problem is isolated to emulators.
I hope this is a temporary issue with the new release because it seems to cripple the whole dev environment.
I'm getting the same issue. I haven't changed a thing in the project after running react-native init.
I don't have more information to add than @awaidmann, but this is immediately after installing everything. So everything I have is the latest version in the install process.
I'm getting the same issue. I had react-native 0.16 and it worked fine.
I deleted the node_module and npm install again (still 0.16)
now i get the SyntaxError: Left hand side of operator '=' must be a reference. error
Update:
I am able to run the existing app on my HTC One (Android: 5.0.2, HTC Sense: 6.0), but for some reason the newly init'ed project is still having issues. I am now getting the error log:

I assume the two issues are related, but I am not familiar enough with react-native to know how or why.
Was just helping an engineer on my team get our react-native project set up, and he's running into the same issue. I upgraded to 0.17 yesterday and did not run into any trouble.
+1 on this. Running android 0.17. An open source project that compiled and ran cleanly yesterday does not work all of a sudden.
Since this issue is just popping up now, I wonder if something changed with Babel upstream...
I think this is due to a new babel release (6.4.0) which has breaking changes
I think this is the upstream bug: https://phabricator.babeljs.io/T6926
@sneuberger thanks for digging that up.
Same here, tried 0.17 and 0.18.0-rc but result is the same.
Babel just published a hotfix -- skevy is testing to see if it resolves the RN issue.
Hey y'all - can you all try again? Just re-npm install. It should pull the latest version of 6.4.1
(You'll probably need to delete node_modules, just to be safe)
works for me, thanks!
Awesome, thanks for the confirmation @skevy & @ben-manes. Going to be optimistic here and am closing this out.
How to fix this:
- Clear your npm cache:
npm cache clean - Clear your node_modules:
rm -rf node_modules - Install your node_modules again:
npm install
FYI - Not getting the 6.4.1 when I blow away node_modules and re npm install. Still pulling [email protected]
@steakchaser that's weird, but could you try running npm cache clean?
Yeah, when I follow those steps I'm still getting 6.4.0. When I run npm info babel-core the last entry in the versions array says 6.4.0, and not 6.4.1 like I would expect. npm cache clean doesn't fix it for me either.