create-react-native-app won't start with yarn or npm

Created on 14 Mar 2018  路  4Comments  路  Source: expo/create-react-native-app

Description

I understand there's a bug with NPM5 and CRNA, so I installed it with Yarn. I installed my new app, went into it's folder and entered 'yarn start' just as the command prompted me to do. I got an error.

I don't know if it matters, but npm start does work for other react apps, it's only react-native that's giving me this problem.

Expected Behavior

Start the development build for a react app.

Observed Behavior

Jonathans-MBP:my-native-app jonathankuhl$ yarn start
yarn run v1.5.1
$ react-native-scripts start
16:43:13: 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

error An unexpected error occurred: "Command failed.
Exit code: 1
Command: sh
Arguments: -c react-native-scripts start
Directory: /Users/jonathankuhl/Documents/Programming/react/my-native-app
Output:
".
info If you think this is a bug, please open a bug report with the information provided in "/Users/jonathankuhl/Documents/Programming/react/my-native-app/yarn-error.log".
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Environment

Please run these commands in the project folder and fill in their results:

Also specify:

  1. Operating system: Mac OS
  2. Phone/emulator/simulator & version: Haven't gotten that far

Most helpful comment

I'd recommend trying with Watchman installed. You can run brew install watchman to get it.

All 4 comments

I'd recommend trying with Watchman installed. You can run brew install watchman to get it.

I didn't realize watchman was needed. My bad.

it's in the error message ;)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

witbybit picture witbybit  路  4Comments

FezVrasta picture FezVrasta  路  3Comments

andyvanosdale picture andyvanosdale  路  3Comments

tonyhb picture tonyhb  路  5Comments

scf4 picture scf4  路  5Comments