node_modules is not installed during exp init

How to resolve this issue. when i run expo init command expo created without node_modules.

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

Starting project at C:\Users\Hazrat Bilal\Desktop\Pizz-App
Expo DevTools is running at http://localhost:19002
Opening DevTools in the browser… (press shift-d to disable)
Your project is in SDK version >= 33.0.0, but the expo package version seems to be older.
Error: node_modules directory is missing. Please run npm install in your project directory.
Couldn’t start project. Please fix the errors and restart the project.
Error: Couldn’t start project. Please fix the errors and restart the project.
at startExpoServerAsync (C:@expo\xdl@57.5.4\src\Project.ts:2003:11)
at Object.startAsync (C:@expo\xdl@57.5.4\src\Project.ts:2402:5)
at action (C:\expo-cli@3.13.5\src\commands\start.ts:131:3)
at C:\expo-cli@3.13.5\src\commands\start.ts:293:16
at Command. (C:\expo-cli@3.13.5\src\exp.ts:83:7)

Did you run exp init? or expo init?

exp is old and deprecated. You should be using expo.

1 Like

Thanks for your respoce.

Yes i also tried expo init but gave the same error.

Did you get any warnings/errors when running expo init?

As a workaround, run npm install before running expo start.

1 Like

I got this error when running 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! code ERR_OSSL_PEM_NO_START_LINE
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-13T06_31_08_072Z-debug.log

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

I also tried node-v10.19.0-x64,v12.10.0-x64 and v12.16.1-x64 but got the same error when i run expo init.

Hmmm… clearly there’s an issue related to npm and SSL certificates. I can’t tell what the problem is based on the error message. Maybe you could try installing yarn instead, but I have no idea if that will work better.

1 Like

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