main.jsbundle, Foundation and Security missing in the project, causing error

前端 未结 4 504
我在风中等你
我在风中等你 2021-02-01 22:43

I\'ve noticed that file main.jsbundle file is missing from the project and am not sure of how to fix it, should I delete the file / is there a step I can perform to

4条回答
  •  渐次进展
    2021-02-01 23:28

    If you're ejecting from create-react-native-app on react-native v0.50+ the index.ios.js and index.android.js files are now combined into index.js

    Before or after ejecting run

    npm i -g react-native-cli if you npm install

    or

    yarn global add react-native-cli if you yarn install

    ...After Ejecting...

    [bad advice]run react-native bundle --entry-file ./index.js --platform ios --bundle-output ios/main.jsbundle . <-- Do Not do this.

    [UPDATE] The main.jsbundle is created when xcode opens the terminal bundler. make sure you don't close the terminal window and it will run fine.

提交回复
热议问题