I created a new project using
react-native init Wevaha
,after that I excute it work's properly then I modified sample app based on my requirement again run it works properly but the next time while running the app I am gettingthe error like' Application Wevaha has not been registered.This is either due to a require() error during intialization or failure to call
AppRegistry.registerComponent'
The screen shot attached below please find it
AppRegistry is the JS entry point to running all React Native apps. App root components should register themselves with AppRegistry. registerComponent , then the native system can load the bundle for the app and then actually run the app when it's ready by invoking AppRegistry. runApplication .
Invariant Violation: "main" has not been registered. This can happen if: * Metro (the local dev server) is run from the wrong folder. Check if Metro is running, stop it and restart it in the current project. * A module failed to load due to an error and `AppRegistry.
index. js is the starting point for React Native applications, and it is always required.
It is likely that you already have another React Native packager server running for another app or that the app name in AppDelegate.m and your index.js is not the same.
Try closing all terminal windows, double check the value of moduleName
and run the project again.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With