当我运行react-native run-android
时,我得到一个react native配置错误。该命令给出以下错误消息:
JS server already running.
Building and installing the app on the device (cd android && gradlew.bat installDebug)...
Error: Could not find or load main class JAVA_OPTS=-Xms256M
Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/getting-started.html
我不能解决这个问题。我安装了所有依赖项。我的模拟器也正在运行,但是应用程序无法启动。
答案 0 :(得分:0)
尝试设置您的Android开发环境。配置环境变量(如路径),请确保在运行时找到您的android sdk工具(如adb)!