为什么我的阵营我的设备上本机应用程序运行

问题描述:

我希望能够以测试Expo我的应用程序(一个IPhone应用程序来测试您做出反应击中后保存本机代码),我只是似乎无法得到过去这个错误我得到Terminal。我已经跑了使用Expo我的应用程序没有问题之前,但现在要包括Navigator在我的应用程序后,我得到一个错误。为什么我的阵营我的设备上本机应用程序运行

首先,我这样做:

$ npm i -g create-react-native-app 
$ create-react-native-app my-project 
$ cd my-project` 

然后,我想包括Navigator在我的应用程序,所以我继续这样做:

npm install --save react-navigation

之后,为了得到Expo正在运行我做过:

npm start

当我做npm start,我得到这个错误Terminal

npm ERR! file sh 
npm ERR! code ELIFECYCLE 
npm ERR! errno ENOENT 
npm ERR! syscall spawn 
npm ERR! [email protected] start: `react-native-scripts start` 
npm ERR! spawn ENOENT 
npm ERR! 
npm ERR! Failed at the [email protected] start script. 
npm ERR! This is probably not a problem with npm. There is likely additional logging output above. 

npm ERR! A complete log of this run can be found in: 
+0

是'反应,本机安装scripts'? – vijayst

+0

@vijayst我不这么认为。我会如何去做这件事? –

+0

'NPM我反应过来,本机scripts' – vijayst

我的猜测是,你正在使用npm5,我会建议使用npm4,npm5目前(如2017年6月17日的)非常越野车。 see this recommendation in the README