In Microsoft visual studio 2022 I have created blank JavaScript project. I want to debug and put breakpoint in app.js and play Launch Chrome button. It popup and error “There were deployment erros.continue?” below is my build commands
Build started at 3:36 PM...
1>------ Build started: Project: NodeConsoleApp2, Configuration: Debug Any CPU ------
2>------ Deploy started: Project: NodeConsoleApp2, Configuration: Debug Any CPU ------
2>Starting deployment of project 'C:UsersAsussourcereposNodeConsoleApp2NodeConsoleApp2NodeConsoleApp2.esproj'...
2>Launching the following configuration from launch.json:
2>
2>Deployment of project 'C:UsersAsussourcereposNodeConsoleApp2NodeConsoleApp2NodeConsoleApp2.esproj' failed. Port unavailable: -1
2>An exception happened at deploy, the port -1 configured on launch.json is unavailable.
========== Build: 1 succeeded or up-to-date, 0 failed, 0 skipped ==========
========== Build completed at 3:36 PM and took 01.674 seconds ==========
========== Deploy: 0 succeeded, 1 failed, 0 skipped ==========
========== Deploy completed at 3:36 PM and took 01.674 seconds ==========
Here is my launch.json file below
{
"version": "0.2.0",
"configurations": [
{
"name": "Launch Chrome",
"type": "chrome",
"request": "launch",
"url": "chrome://extensions/",
"port": 9222,
"runtimeArgs": [
"--load-extension=${workspaceFolder}/output/build",
"--remote-debugging-port=9222"
]
}
]
}
If i continue then i get another error
Failed to load extension from:
C:UuserAsussourcereposNodeConsoleApp2NodeConsoleApp2outputbuild. Manifest file is missing or unreadable
So I would like to debug JavaScript application in chrome, how can a able to achieve this, is it really possible? I am using windows 11, should i need any modification in launch.json. should i need any configuration in visual studio below i have provided some information images. thanks
I have created blank javascript project in microsoft visual studio 2022. Then I have changed below code in launch.json file want to debug in chrome browser but i am getting error, So i want build the project and debug in chrome browser.
"name": "Launch Chrome",
"type": "chrome",
"request": "launch",
"url": "chrome://extensions/",
"port": 9222,
"runtimeArgs": [
"--load-extension=${workspaceFolder}/output/build",
"--remote-debugging-port=9222"
]