Please make our job easier by filling this template out to completion. If you're requesting a feature instead of reporting a bug, please feel free to skip the Environment and Reproducible Demo sections.
Getting this error after latest update:
Warning: React.createElement: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: object. You likely forgot to export your component from the file it's defined in. Check the render method of `AwakeInDevApp`.
I setup a basic application using Redux.
I am unable to render the application in Expo because of this error.
If there's an error message, please paste the full terminal output and error message in this code block:
8:15:00 AM: Bundling `node_modules/react-native-scripts/build/bin/crna-entry.js`
No module changed.
8:15:00 AM: Loading your app...
8:15:01 AM: Warning: React.createElement: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: object. You likely forgot to export your component from the file it's defined in. Check the render method of `AwakeInDevApp`.
Please run these commands in the project folder and fill in their results:
npm ls react-native-scripts: [email protected]npm ls react-native: [email protected]npm ls expo: [email protected]node -v: v7.8.0npm -v: 4.2.0yarn --version: N/Awatchman version: N/AAlso specify:
Here's a repo I setup with the code: https://github.com/mwq27/rn-poc
Thanks for the detailed report and the reproduction! It looks like your App.js no longer exports a default component after your redux changes, and it also looks like you've added your own call to AppRegistry, which should instead be handled by CRNA. Can you try following the template and see if that fixes this?
Yep, that was the problem. I removed that AppRegistry call and exported the component instead.
Thanks
Awesome!
what template? I looked at https://github.com/mwq27/rn-poc/blob/master/App.js and it looks like you have AppRegistry. I'm confused
@mwq27 Gracias. resolvi贸 mi problema
Most helpful comment
Thanks for the detailed report and the reproduction! It looks like your App.js no longer exports a default component after your redux changes, and it also looks like you've added your own call to AppRegistry, which should instead be handled by CRNA. Can you try following the template and see if that fixes this?