Reputation: 261
Trying to run a react-native project but I am getting this error:
Unable to resolve "/Users/bobby/node_modules/babel-runtime/regenerator" from "App.js"
What are some possible solutions to this issue?
My iOS simulator is giving me a red screen and saying this:
Unable to resolve module
/Users/bobby/node_modules/babel-runtime/regenerator
from/Users/bobby/Desktop/mstore/src/App.js
: The module/Users/bobby/node_modules/babel-runtime/regenerator
could not be found from/Users/bobby/Desktop/mstore/src/App.js
. Indeed, none of these files exist:
/Users/bobby/node_modules/babel-runtime/regenerator(.native||.ios.js|.native.js|.js|.ios.json|.native.json|.json)
/Users/bobby/node_modules/babel-runtime/regenerator/index(.native||.ios.js|.native.js|.js|.ios.json|.native.json|.json)
ABI28_0_0RCTFatal 37-[ABI28_0_0RCTCxxBridge handleError:]_block_invoke _dispatch_call_block_and_release _dispatch_client_callout _dispatch_main_queue_callback_4CF __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE __CFRunLoopRun CFRunLoopRunSpecific GSEventRunModal UIApplicationMain main start 0x0
Upvotes: 2
Views: 9310
Reputation: 107
install babel/poylfill and put it at the top of your app entry point
Upvotes: 1
Reputation: 261
Was on macOS Mojave (beta software). Downgraded to latest stable release version (High Sierra) and everything appears to be working now.
Upvotes: -3
Reputation: 4983
Update your npm:
npm i npm@latest -g
You need to reinstall the babel-runtime
, you need to have babel-runtime@6 in your dependencies.
npm i babel-runtime
Upvotes: 2