-
Notifications
You must be signed in to change notification settings - Fork 2
Debugging with Visual Studio Code
boukestam edited this page Jun 21, 2018
·
1 revision
- Install the NetJS debug extension from the Visual Studio Code marketplace.
- Create a new folder in your project root called ".vscode"
- Create a new file in that folder called "launch.json".
- Add the following JSON:
{
"version": "0.2.0",
"configurations": [
{
"type": "netjs",
"request": "launch",
"name": "Debug NetJS",
"program": "ws://localhost/debug",
"localRoot": "${workspaceRoot}"
}
]
}- Replace "localhost" with your server url, keep /debug
- Set a breakpoint somewhere in your code
- Go to the debug tab in Visual Studio Code and press the green triangle to start debugging
- Reload the page to trigger the breakpoint