so i'm trying to install brain.js in my project so i can use it
to create a kind of chat app, trying to install it however gives me an error
i'v read in places you need 64 bit version of node and i'm fairly sure i have
that, i reinstalled it using nvm ( node version manager )
node -v returns v16.13.1
npm install brain.js
heres the error log it outputs:
https://pastebin.com/raw/xukfQJLY
Related
Each time I use angular/cli to create a new project by launching the following command
ng new Project-Name
I get the following error
npm ERR! Unexpected end of JSON input while parsing near '...-4","#angular/common"'
I tried to force clean the cache and re-try but still face the same problem.
NodeJS version: 12.16.3
npm version: 6.14.4
Angular CLI version: 9.1.4
OS: Windows 10 Home win32 x64
Edit: All the commands above I run them in Powershell as administrator
This is not a definitive answer but it looks like your global packages are corrupted in some way.
This bug may be caused by many different things. I suggest doing the following.
Install Node Version Manager (or NVM for Windows) and install Node version 10.16.1. This is enough for angular 9 and from my experience it is the most stable version for development. This should also change your NPM version so that may also help.
Uninstall global angular package npm uninstall -g #angular/cli
Force clear cache npm cache clean --force
Just to double check npm cache verify
You can also try clearing your %temp% and %roaming% AppData/npm-cache
install latest angular package npm install -g #angular/cli#<your-version>
if this error still occurs, consider using another shell
If this don't solve the problem try to manually locate the package.json file that is throwing an error and investigate.
I'm trying to do an install but it requires node.js 11 or below. I am using nvm and change to v9.0.0.
node -v shows v9.0.0 but then when I do rush install it says my version is 12.(can't remember exact version)
Why would I get this error even after node -v tells me I'm using v9.0.0?
I'm on Ubuntu.
While hosting my webapp on heroku I got a message of some bugs in my npm package, my npm package was of version 3 and node.js was of version 8, I wrote thinking that I can update my npm version I tried to update it but the version remained same so I decided to uninstall it and wrote the command "npm uninstall " and than again tried to install npm but in vain ,finally I uninstalled my node.js and reinstalled tha npm will automatically get installed with it, but this too didn't work now I have node of version 10 with no npm which I got to know by checking version of npm which gave me message of "command not found ", now my every try to install npm has failed , may anyone suggest me what I can do to restore my losses and resume my work.
I am not sure if you have Linux or Windows. First I would check if the npm folder is in path.
You can follow one of these two to add to path if it is not done yet.
Windows
Linux
Alternatively you can install node with node version manager (nvm):
nvm linux and mac
nvm windows
i downloaded nodejs and installed with node package manager.
After installing when i typed..
node -v
i am getting response as
v.6.11.1
But when i type
npm -v
i am not gettin any response.then when i give ctrl+c to terminate i am getting response as
Terminate batch job(y/n)?
I have tried reinstalling several times but couldnt able to run npm installation.Any help?
I think node js is not installed properly in your system.
Try to reinstall it and then do this process again.
Follow these steps you will get the node and npm installation successful:
download Nodejs from the link https://nodejs.org/en/
download V6.11.1 LTS (long term support)
type npm install -g #angular/cli in the command promt
check the version now by typing npm -v in the command prompt and node -v
It may not installed properly, Reinstall npm
Try this link https://nodejs.org/en/download/package-manager/
I am trying to install the environment for react native.
I followed the instruction of the site until the point to enter into the cmd
create-react-native-app AwesomeProject
after several moments I get a big green message:
You are currently running Node v0.12.2.
React Native runs on Node 4.0 or newer. There are several ways to
upgrade Node.js depending on your preference.
nvm: nvm install node && nvm alias default node
Homebrew: brew unlink iojs; brew install node
Installer: download the Mac .pkg from https://nodejs.org/
About Node.js: https://nodejs.org
Follow along at: https://github.com/facebook/react-native/issues/2545
I try to upgrade my nodejs but I have the newest version form the site.
why does it still throws me this error ?
Hi user24136 i build react native apps myself and i have latest Node version running. Error states your Node.js installed is old and React Native does run on Node 4.0+. Seems like your on a Mac, visit this link Node.js and use installer to upgrade your NPM and Node to latest versions. After successful installations run commands node -v and npm -v and you should see newer version v6.10.3 and 3.10.10 respectively. Then run command react-native init AwesomeProject and check if it works.
This problem interested in from your only node version
you can use sudo n stable command your terminal. This command increase your node version.