我已经安装了 node 8.10 并降级到 npm 4,因为我有 npm 5 的错误消息。
*******************************************************************************
ERROR: npm 5 is not supported yet
Run Code Online (Sandbox Code Playgroud)
然后我使用命令降级 npm npm install -g npm@4。
所以我创建了我的项目
$>npm install -g create-react-native-app
$>create-react-native-app AwesomeProject
$>cd AwesomeProject
$>npm start
Run Code Online (Sandbox Code Playgroud)
然后我有以下错误消息。
> AwesomeProject@0.1.0 start /private/var/root/AwesomeProject
> react-native-scripts start
09:42:16: Unable to start server
See https://git.io/v5vcn for more information, either install watchman or run the following snippet:
sudo sysctl -w kern.maxfiles=5242880
sudo sysctl -w kern.maxfilesperproc=524288
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! AwesomeProject@0.1.0 start: …Run Code Online (Sandbox Code Playgroud)