npm install nodemon -g
nodemon app.js
If you don’t want to set the environment variable, another option is to modify the scripts
part of package.json from:
"start": "react-scripts start"
to
Linux (tested on Ubuntu 14.04/16.04) and MacOS (tested by @aswin-s on MacOS Sierra 10.12.4):
"start": "PORT=3006 react-scripts start"
or (may be) more general solution by @IsaacPak
"start": "export PORT=3006 react-scripts start"
Windows @JacobEnsor solution
"start": "set PORT=3006 && react-scripts start"
export PORT=3005
npm start
How to run React Node.js Yarn from git hub source
check version
node -v: v6.11.1
npm -v: 5.3.0
yarn --version (if you use Yarn):
Firstly Delete package-lock.json file in your project folder.
And then install dependencies again by npm install. That should solve this issue.
npm install
Steps to Reproduce
(Write your steps here:)
npm install -g create-react-app
create-react-app my-app ... cd my-app/
npm start
https://github.com/nodesource/distributions/blob/master/README.md
https://nuxtjs.org/docs/2.x/get-started/installation
https://nodejs.org/en/docs/guides/nodejs-docker-webapp/
https://linuxize.com/post/how-to-install-node-js-on-ubuntu-20-04/
Be First to Comment