react-native init project出错



  • E:\code\javascript\reactNative>react-native init MyProject
    This will walk you through creating a new React Native project in E:\code\javascript\reactNative\MyProject
    Installing react-native package from npm...
    events.js:141
    throw er; // Unhandled 'error' event
    ^

    Error: spawn npm ENOENT
    at exports._errnoException (util.js:855:11)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:178:32)
    at onErrorNT (internal/child_process.js:344:16)
    at nextTickCallbackWith2Args (node.js:455:9)
    at process._tickCallback (node.js:369:17)
    at Function.Module.runMain (module.js:432:11)
    at startup (node.js:141:18)
    at node.js:980:3