Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

error: Expected node to be of a type ["Statement"] but instead got "AssignmentExpression" | React Native IOS

I'm having this problem when trying to run react native app on ios emulator. I literally just created the project running npx react-native init app_test and when I run npx react-native run-ios I got this error.

enter image description here

I'm not installing dependencies or pods or anything. Just running yarn start when the app init is done and trying to run the emulator. Any suggestion by any chance plz?

Error in console: error: node_modules/react-native/Libraries/Image/ImageAnalyticsTagContext.js: Property body[6] of BlockStatement expected node to be of a type ["Statement"] but instead got "AssignmentExpression"

like image 625
Mcrunny Avatar asked Aug 05 '21 01:08

Mcrunny


1 Answers

You may want to check this solution out: https://github.com/facebook/react-native/issues/31960#issuecomment-893176992.

It seems there is a problem with @babel/[email protected] which has been released along with @babel/[email protected] a couple of hours ago.

like image 125
Javan Huang Avatar answered Nov 05 '22 16:11

Javan Huang