reactjs - Visual Studio Code is not npm start-ing my React JS app when debugging -


i want debug react js app on visual studio code i'm following tutorial: https://code.visualstudio.com/docs/nodejs/reactjs-tutorial

i'm stuck at:

ensure development server running ("npm start"). press f5 or green arrow launch debugger , open new browser instance.

a new chrome instance being opened requesting "http://localhost:3000" app not running, seems ran debugger.

if mannually npm start app runs. guess launch.json missing visual studio code start app debugger. that's why i'm stuck @ ensuring development server running command, because don't know check this

this launch.json:

{     "version": "0.2.0",     "configurations": [         {             "type": "chrome",             "request": "launch",             "name": "launch chrome against localhost",             "url": "http://localhost:3000",             "webroot": "${workspaceroot}"         },         {             "type": "chrome",             "request": "attach",             "name": "attach chrome",             "port": 9222,             "webroot": "${workspaceroot}"         }     ] } 

and package.json:

{   "name": "tic-tac-toe",   "version": "0.1.0",   "private": true,   "dependencies": {     "react": "^15.6.1",     "react-dom": "^15.6.1",     "react-scripts": "1.0.11"   },   "scripts": {     "start": "react-scripts start",     "build": "react-scripts build",     "test": "react-scripts test --env=jsdom",     "eject": "react-scripts eject"   } } 

i'm not sure if that's possible. tutorial says should ensure development server runs. so, you'll have first run npm startand debug afterwards.


Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -