Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't find variable: _objectSpread

I'm building a react native app and running into the following error when I run react-native run-ios

Can't find variable: _objectSpread.

Does anyone have any tips?

I think it might be my react-native version but not sure.

Here are my dependencies:

 "dependencies": {
    "metro-react-native-babel-preset": "^0.55.0",
    "query-string": "^6.8.1",
    "react": "^16.8.6",
    "react-native": "0.56.0",
    "react-native-animatable": "^1.3.2",
    "react-native-cli": "^2.0.1",
    "react-native-elements": "^1.1.0",
    "react-native-gesture-handler": "^1.3.0",
    "react-native-maps": "^0.25.0",
    "react-native-table-component": "^1.2.0",
    "react-native-vector-icons": "^6.6.0",
    "react-navigation": "^3.11.1"
  },
like image 383
Alan Zhao Avatar asked Nov 17 '25 23:11

Alan Zhao


1 Answers

This is a known issue, please update your package.json to reflect these changes and it should work:

"@babel/core": "^7.5.0", "@babel/runtime": "^7.5.0"

like image 111
Tushar Gupta Avatar answered Nov 20 '25 13:11

Tushar Gupta



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!