Collectives™ on Stack Overflow

Find centralized, trusted content and collaborate around the technologies you use most.

Learn more about Collectives

Teams

Q&A for work

Connect and share knowledge within a single location that is structured and easy to search.

Learn more about Teams

This will walk you through creating a new React Native project in C:\Program Fil es\AwesomeProject Installing react-native package from npm... events.js:141 throw er; // Unhandled 'error' event

Error: spawn npm ENOENT at exports._errnoException (util.js:860:11) at Process.ChildProcess._handle.onexit (internal/child_process.js:178:32) at onErrorNT (internal/child_process.js:344:16) at doNTCallback2 (node.js:450:9) at process._tickCallback (node.js:364:17) at Function.Module.runMain (module.js:459:11) at startup (node.js:136:18) at node.js:972:3

How do I fix this?

Does the path C:\Program Files\AwesomeProject exist and if not can your current user create it with their set of permissions? tkone Jan 6, 2016 at 18:35 @tkone, yes it does. It has 1 file package.json with the following code there {"name":"AwesomeProject","version":"0.0.1","private":true,"scripts":{"start":"node node_modules/react-native/local-cli/cli.js start"}} user2950593 Jan 6, 2016 at 19:02 is there anymore to your error message? ENOENT means that its trying to access a directory/file that doesn't exist. Can you change the log level on the command? tkone Jan 6, 2016 at 19:11 So apparently this was fixed in react-native 0.1.9 in windows as long as you don't use the --verbose feature in your init call, ref: github.com/facebook/react-native/issues/5414 zipzit May 10, 2016 at 17:05

This should be fixed in React Native CLI 0.1.9. To update your CLI:

npm uninstall -g react-native-cli
npm install -g react-native-cli

There was a regression in 0.1.8, reported here: https://github.com/facebook/react-native/issues/5169

Could you please elaborate on how to solve the issue if there is no other projects at hand? – Oleg Kurbatov Apr 22, 2020 at 17:12 Thanks for answering, but this could communicate a lot better if you used text instead of an image and full sentences. – Brad Koch Jan 7, 2016 at 1:38

Thanks for contributing an answer to Stack Overflow!

  • Please be sure to answer the question. Provide details and share your research!

But avoid

  • Asking for help, clarification, or responding to other answers.
  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.