npm exited with non-zero code: 1

Hi,
I’m a complete beginner to React Native.
I first installed node.js 12.16.1, then expo by executing npm install -g expo-cli , it has been executed correctly.

Then I tried to create my first expo app by executing the following script:
cd desktop
expo init PizzaApp
I choosed a blank template.
After executing, I got the message npm exited with non-zero code 1

When i run expo diagnostics I got the following

Expo CLI 3.13.5 environment info:
System:
OS: Windows 10 10.0.18362
Binaries:
Node: 12.16.1 - C:\Program Files\nodejs\node.EXE
npm: 6.14.2 - C:\Program Files\nodejs\npm.CMD

Could please any body tell what is it? and how to resolve.

I will be thankful…!

Don’t use node v12. Stick with v10.19

1 Like

Thanks for your response.

I uninstalled the node v12 and installed the node v10.19 and then run npm install -g expo-cli and this install the expo but when run expo init that gave me the same error.

Here i am mentioning the error which i got after expo init

C:\Repos>expo init pizzaApp
? Choose a template: expo-template-blank
Using npm to install packages. You can pass --yarn to use Yarn instead.
Extracting project files…
Customizing project…
Initialized a git repository.
Installing dependencies…

npm install
npm WARN deprecated deep-assign@3.0.0: Check out lodash.merge or merge-options instead.
npm WARN deprecated core-js@2.6.11: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
npm WARN deprecated core-js@1.2.7: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
npm ERR! error:0909006C:PEM routines:get_name:no start line

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Hazrat Bilal\AppData\Roaming\npm-cache_logs\2020-03-12T10_40_42_351Z-debug.log

npm exited with non-zero code: 1
Set EXPO_DEBUG=true in your env to view the stack trace.

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.