在 react-native 运行-android 命令上从 运行ning 禁用 JS 服务器

Disabling JS Server from running on react-native run-android command

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/

有没有办法避免启动 JS 服务器

在内部,react-native run-android 在 gradlew 上启动打包程序和 运行 installDebug 任务。

只是 运行 installDebug,在你的项目根目录 运行:

cd android && ./gradlew installDebug