If the above error occurs, first confirm whether the RN service runs successfully
In some cases, the startup fails, or it is shut down unexpectedly after startup, or the ports are inconsistent.
Another situation is recorded here:
If it is a project from the new cluster on GitHub, the directory of Android\app\SRC\main\assets may be empty (the assets folder needs to be created). At this time, it needs to be run under the terminal of the project root directory:
react-native bundle --platform android --dev false --entry-file index.android.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res/
To create the missing file
After running, you will see the missing index on the red screen android. Bundle file.
Run it again and the problem is solved.
Read More:
- React-native Error: Make sure you have the Android development environment set up [Solved]
- Solve the problem that the native machine cannot use ant script checkout project
- [Solved] Tensorflow Error: Failed to load the native TensorFlow runtime.
- [Solved] VScode powershell Run ts-node Error: Unable to load file xxxx…
- [Solved] react Error: Can‘t perform a React state update on an unmounted component
- Android Phone Record Screen Error: failed to get surface
- React Hook “useState“ is called in function “xxx“ which is neither a React function component or
- [Solved] Flyter uses screenutil to obtain screen width and height initialization error
- [Solved] Xcode13.1 Upgrade Error: CocoaPods installed but not working Failed to build gem native extension
- [Solved] react18 swiper Error: Cannot read properties of undefined (reading ‘wrapperClass’)
- NPM install -g create-react-app [How to Solve]
- Taro Use React Hooks Error: TypeError: Object(…) is not a function
- [Solved] Azkaban Error: Missing required property ‘azkaban.native.lib’
- [Solved] matlab error: try to write SCRIPT vl_sift is executed as a function
- org/sqlite/native/Mac/aarch64 Error [How to Solve]
- How to Solve NPM run dev error: missing script:dev
- [Solved] Android Studio Error: ERROR: Cause: executing external native build for cmake
- Kubernetes Error: Error in configuration: unable to read client-cert* unable to read client-key*
- Cocoapods Install ERROR: Error installing cocoapods: ERROR: Failed to build gem native extension.
- Attempted import error: ‘mobx-react‘ does not contain a default export (imported as ‘observer‘).