我用控制台命令react-native init myApp --template react-native-template-typescript
创建了一个新项目。
然后,我在vs code
中打开项目文件夹,并在两个终端中运行命令。
第1航站楼日志
user1@ps:~/documents/projects/myApp$ npx react-native start
┌──────────────────────────────────────────────────────────────────────────────┐
│ │
│ Running Metro Bundler on port 8081. │
│ │
│ Keep Metro running while developing on any JS projects. Feel free to │
│ close this tab and run your own Metro instance if you prefer. │
│ │
│ https://github.com/facebook/react-native │
│ │
└──────────────────────────────────────────────────────────────────────────────┘
Looking for JS files in
/home/user1/documents/projects/myApp
Loading dependency graph, done.
第2航站楼日志
user1@ps:~/documents/projects/myApp$ npx react-native run-android
info Running jetifier to migrate libraries to AndroidX. You can disable it using "--no-jetifier" flag.
Jetifier found 864 file(s) to forward-jetify. Using 4 workers...
info JS server already running.
info Installing the app...
Starting a Gradle Daemon, 1 busy and 3 stopped Daemons could not be reused, use --status for details
> Task :app:stripDebugDebugSymbols UP-TO-DATE
Compatible side by side NDK version was not found.
<============-> 99% EXECUTING [10m 45s]
> IDLE
> IDLE
> :app:installDebug
> IDLE
此后,将进行永久下载。
我在android studio
中打开了android文件夹,并启动了该项目,它成功运行并启动。
我无法使用npx react-native run-android
中的vs code
命令启动项目是什么问题?
我还应该添加什么其他信息来解决我的问题?