用android studio 打包成apk 文件

js build

执行:

react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res/

进入Android studio 

react-native 打包成apk 文件

坐等

react-native 打包成apk 文件

问?为啥要build js

原生应用提供了js 的运行环境,实际上我们还是要把工程打包成js文件,实际执行时也是在js解析器中执行的,也因此会比原生性能稍稍逊色;

 

相关文章:

  • 2021-07-03
  • 2022-12-23
  • 2021-06-06
  • 2021-12-17
  • 2022-12-23
  • 2021-09-17
  • 2022-12-23
猜你喜欢
  • 2021-04-10
  • 2021-08-21
  • 2022-12-23
  • 2022-12-23
  • 2022-01-29
相关资源
相似解决方案