'Cannot find module node_modules\chalk\source'. Please verify that the package.json has a valid "main" entry
I updated node, npm and expo-cli now I'm facing this issue every time i run "Npm start"
Cannot find module 'C:\Users\xyz\projects\abc\node_modules\chalk\source'. Please verify that the package.json has a valid "main" entry
Error: Cannot find module 'C:\Users\xyz\projects\abc\node_modules\chalk\source'. Please verify that the package.json has a valid "main" entry
at tryPackage (node:internal/modules/cjs/loader:353:19)
at Function.Module._findPath (node:internal/modules/cjs/loader:566:18)
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:919:27)
at Function.Module._load (node:internal/modules/cjs/loader:778:27)
at Module.require (node:internal/modules/cjs/loader:1005:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Object.<anonymous> (C:\Users\xyz\projects\abc\node_modules\metro\src\index.js:110:15)
at Module._compile (node:internal/modules/cjs/loader:1101:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
Metro Bundler doesn't start. Anyone who's facing the same issue? any help would be appreciated.
Solution 1:[1]
rm -rf node_modules && npm install
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Ivan Krivtsov |
