npm ERR! Unexpected end of JSON input while parsing near '...#types/run-sequence":'
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Acer\AppData\Roaming\npm-cache_logs\2020-05-24T09_59_48_560Z-debug.log
× Package install failed, see above.
The Schematic workflow failed. See above.
When I create a new angular project using "ng new newApp", Above error occured. I tried so many solutions, but did not work.
I just uninstalled angular using the command,
npm uninstall -g #angular/cli
Then I cleared the cache using the following command,
npm cache clean --force
Then I reinstalled angular,
npm install -g #angular/cli
Then it worked successfully.
I am new to Foundation for Emails and I am just trying to get everything installed, following directions step by step. I have installed Git, and Node.js (the latest version 11.5.0).
I created my project directory (test123) and inside there I am told to run "npm start". I do this and get the following error:
Alexandrus-MacBook-Pro-2:test123 alexcrisan$ npm start
> foundation-emails-template#1.0.0 start. /Users/alexcrisan/Documents/sites/test123
> gulp
[09:27:55] Failed to load external module #babel/register
[09:27:55] Failed to load external module babel-register
[09:27:55] Failed to load external module babel-core/register
[09:27:55] Failed to load external module babel/register
[09:27:55] Local gulp not found in ~/Documents/sites/test123
[09:27:55] Try running: npm install gulp
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! foundation-emails-template#1.0.0 start: `gulp`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the foundation-emails-template#1.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/alexcrisan/.npm/_logs/2018-12-26T14_27_55_973Z-debug.log
I follow the error code to install gulp, and get this:
Alexandrus-MacBook-Pro-2:test123 alexcrisan$ npm install gulp
npm ERR! code 1
npm ERR! Command failed: /usr/bin/git checkout 4.0
npm ERR! error: pathspec '4.0' did not match any file(s) known to git.
npm ERR!
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/alexcrisan/.npm/_logs/2018-12-26T15_03_01_008Z-debug.log
I found some similar answers online but couldn't find a straightforward way to solve this without digging myself into more confusion.
Running Mac OS Mojave (latest).
Thank you!
The git release name of gulp has changed from 4.0 to v4.0.0 which means that git cant find the node module to install it.
if you open your package.json and you should see something like:
"gulp": "github:gulpjs/gulp#4.0",
replace it with:
"gulp": "github:gulpjs/gulp#v4.0.0",
Then delete your node-modules folder and reinstall, it should run fine now.
I know how you feel, this had me confused for a while. To resolve it I looked at the released versions on github (https://github.com/gulpjs/gulp/releases) and used the v4.0.0 release in place of what was there.
smartTable it shows below error after doing necessary npm installation
./node_modules/ng2-completer/esm5/ng2-completer.js
Module not found: Error: Can't resolve 'rxjs/Observable' in 'C:\POC\projectMgnt\node_modules\ng2-completer\esm5'
However I can see esm5 folder with ng2-completer.js
Run these two commands in your project directory. Error solved in my case.
npm i rxjs-compat --save
npm i ng2-completer --save
I am going to update npm latest version, but it's showing this error message:
G:\>npm i -g npm ERR! code ENOLOCAL npm ERR!
Could not install from "" as it does not contain a package.json file.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\hemanth\AppData\Roaming\npm-cache\_logs\2018-01-08T03_34_29_774Z-debug.log
G:\>
This is an issue in node which is caused by white space in your windows username (possibly between the first-name and last-name in windows).
run the following command after replacing firstname with your windows user firstname in command prompt with administrator access
npm config set cache "C:\Users\Firstname~1\AppData\Roaming\npm-cache" --global
This worked for me:
npm cache verify
Then I re-ran:
npm install -g create-react-app
And it installed like as expected: Issue resolved
I got same issue because I was using an updated "package-lock.json" file from another system, and there was no "node_modules" folder on system where I got the problem.
You can try to following:
Move "package-lock.json" to some other folder, outside current directory.
npm install
If you are facing with this issue, first you should update npm using the below code:
npm -g install npm
then try to create the React file. It is working 100% for me.
Run CMD in administrator mode and fire below commands in order
Run cmd as administrator
Run npm config edit (You will get notepad editor)
Change prefix variable to C:\Users\AppData\Roaming\npm
npm install -g create-react-app
Go to the link for more npm - EPERM: operation not permitted on Windows
Thanks.
npm cache verify
npm install -g create-react-app
I got error npm ERR! code ENOLOCAL while running npx create-react-app my-app
uninstall and install is worked for me…
npm uninstall -g create-react-app
npm install -g create-react-app
this will upgrade your npx, then run
npx create-react-app my-app
this works fine
This worked for me:
npm install -g degit
is like an upgrade
Please verify, whether your npm has installed create-react-app in
**%AppData%Roaming\npm\node_modules**
if not then install it by using the command
npm install -g create-react-app
I got the same problem while trying to use sevelte with
the command
npx degit sveltejs/template youproject
The following was useful:
install -g degit
In the latest Windows, the firewall will block the node.exe to create package.json.
So turn off the firewall settings and try once. It worked for me.
Run npm ci.
Its works for me.
I'm trying to install gulp in my windows 8 system. When I install npm install -g, it's working fine.
After that, when I install gulp in the required folder, it throws the errors of npm install. When I again install npm in the folder it also throws the errors.