Categories
Mastering Development

npm start does nothing on windows

When I try to run npm start just after creating application with npx create-react-app, it does anything and exits with code 0.

When I try to execute npm start command, I get the following message:

C:\projects\novo-curriculo\ui>npm start

> novo-curriculo-ui@0.1.0 start C:\projects\novo-curriculo\ui
> react-scripts start

When I enable –verbose options, I receive the following logs, which are useless too.

C:\projects\novo-curriculo\ui>npm start --verbose
npm info it worked if it ends with ok
npm verb cli [
npm verb cli   'C:\\Program Files\\nodejs\\node.exe',
npm verb cli   'C:\\Users\\gabriel\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js',
npm verb cli   'start',
npm verb cli   '--verbose'
npm verb cli ]
npm info using npm@6.14.5
npm info using node@v12.16.3
npm verb run-script [ 'prestart', 'start', 'poststart' ]
npm info lifecycle novo-curriculo-ui@0.1.0~prestart: novo-curriculo-ui@0.1.0
npm info lifecycle novo-curriculo-ui@0.1.0~start: novo-curriculo-ui@0.1.0

> novo-curriculo-ui@0.1.0 start C:\projects\novo-curriculo\ui
> react-scripts start

npm verb lifecycle novo-curriculo-ui@0.1.0~start: unsafe-perm in lifecycle true
npm verb lifecycle novo-curriculo-ui@0.1.0~start: PATH: C:\Users\gabriel\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;C:\projects\novo-curriculo\ui\node_modules\.bin;C:\Python38\Scripts\;C:\Python38\;C:\Python27\;C:\Python27\Scripts;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files\PuTTY\;C:\Program Files\Git\cmd;C:\Program Files\Docker\Docker\resources\bin;C:\ProgramData\DockerDesktop\version-bin;C:\ProgramData\chocolatey\bin;C:\Program Files\Java\jdk1.8.0_211\bin;C:\Program Files\nodejs\;C:\Program Files\MySQL\MySQL Shell 8.0\bin\;C:\Users\gabriel\AppData\Local\Microsoft\WindowsApps;C:\Users\gabriel\AppData\Local\Programs\Microsoft VS Code\bin;C:\xampp\php\;C:\Users\gabriel\AppData\Local\ComposerSetup\bin;C:\Users\gabriel\AppData\Roaming\Composer\vendor\bin;C:\Program Files\MySQL\MySQL Workbench 8.0 CE\;C:\sqlite\;C:\Users\gabriel\AppData\Local\Android\Sdk\platform-tools;C:\Users\gabriel\AppData\Local\Android\Sdk\emulator;C:\Users\gabriel\Anaconda3;C:\Users\gabriel\Anaconda3\Scripts;c:\flutter\bin;C:\Users\gabriel\AppData\Roaming\npm
npm verb lifecycle novo-curriculo-ui@0.1.0~start: CWD: C:\projects\novo-curriculo\ui
npm info lifecycle novo-curriculo-ui@0.1.0~poststart: novo-curriculo-ui@0.1.0
npm verb exit [ 0, true ]
npm timing npm Completed in 701ms
npm info ok

Here you can see my package.json:

{
  "name": "novo-curriculo-ui",
  "version": "0.1.0",
  "private": true,
  "dependencies": {
    "@testing-library/jest-dom": "^4.2.4",
    "@testing-library/react": "^9.5.0",
    "@testing-library/user-event": "^7.2.1",
    "react": "^16.13.1",
    "react-dom": "^16.13.1",
    "react-scripts": "3.4.1"
  },
  "scripts": {
    "start": "react-scripts start",
    "build": "react-scripts build",
    "test": "react-scripts test",
    "eject": "react-scripts eject"
  },
  "eslintConfig": {
    "extends": "react-app"
  },
  "browserslist": {
    "production": [
      ">0.2%",
      "not dead",
      "not op_mini all"
    ],
    "development": [
      "last 1 chrome version",
      "last 1 firefox version",
      "last 1 safari version"
    ]
  }
}

The npm configuration:

C:\projects\novo-curriculo\ui>npm config list
; cli configs
metrics-registry = "https://registry.npmjs.org/"
scope = ""
user-agent = "npm/6.14.5 node/v12.16.3 win32 x64"

; userconfig C:\Users\gabriel\.npmrc
ignore-scripts = false

; builtin config undefined
prefix = "C:\\Users\\gabriel\\AppData\\Roaming\\npm"

; node bin location = C:\Program Files\nodejs\node.exe
; cwd = C:\projects\novo-curriculo\ui
; HOME = C:\Users\gabriel
; "npm config ls -l" to show all defaults.

And the npm global configuration.

C:\projects\novo-curriculo\ui>npm config -g list
; cli configs
global = true
metrics-registry = "https://registry.npmjs.org/"
scope = ""
user-agent = "npm/6.14.5 node/v12.16.3 win32 x64"

; userconfig C:\Users\gabriel\.npmrc
ignore-scripts = false

; builtin config undefined
prefix = "C:\\Users\\gabriel\\AppData\\Roaming\\npm"

; node bin location = C:\Program Files\nodejs\node.exe
; cwd = C:\projects\novo-curriculo\ui
; HOME = C:\Users\gabriel
; "npm config ls -l" to show all defaults.

I’ve spend all the day trying to solve this issue, but without success. Does anybody else having this also?

My system information is the following and I’ve tried to run this on command prompt (cmd) and Power Shell – both with the same results.

  • Windows 10 Pro (10.0.18363 Build 18363)
  • NPM 6.14.5
  • v12.16.3

Thank you.

Leave a Reply

Your email address will not be published. Required fields are marked *