Abhishek Dhanraj Shahdeo Abhishek Dhanraj Shahdeo - 1 year ago 139
React JSX Question

npm start showing weird error 1

I am new to react js and I have installed the dependencies for the application. Below is my package file:


"name": "reactapp",
"version": "0.0.0",
"description": "learn and test",
"main": "index.js",
"scripts": {
"start": "webpack-dev-server --hot"
"author": "john doe",
"license": "BSD-2-Clause",
"dependencies": {
"webpack": "~1.13.3",
"webpack-dev-server": "~1.16.2",
"react": "~15.3.2",
"react-dom": "~15.3.2"
"devDependencies": {}

It throws the error:

npm ERR! weird error 1
npm WARN This failure might be due to the use of legacy binary "node"
npm WARN For further explanations, please read

npm ERR! not ok code 0

But, in the terminal while it doesn't show up anything when in scripts it is

"test": "echo \"Error: no test specified\" && exit 1"

Answer Source

You need to use the sudo command while installing the nodejs-legacy

You may try executing sudo apt-get install nodejs-legacy from your command line/shell which will resolve the issue.

Hope this helps!

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download