1. 程式人生 > >react-native---react-native run-android啟動時候報錯"JS server not recognized, continuing with build..."

react-native---react-native run-android啟動時候報錯"JS server not recognized, continuing with build..."

啟動react-native run-android命令進行除錯時候,可能會遇到服務找不到的報錯:

JS server not recognized, continuing with build..

這裡寫圖片描述

此時模擬器上是經典的紅色報錯。。。

解決方法

1.尋找埠

netstat -aon|findstr "8081"

記下ID,如6356
這裡寫圖片描述

2.8081端口占用程序

tasklist|findstr "6356"

通過ID 6356找到佔用8081埠的程序:
這裡寫圖片描述

3.殺死程序
找到WiFimaster.exe,工作管理員殺掉程序

4.重新啟動

react-native
run-android

成功啟動8081,
這裡寫圖片描述