Skip to content

Commit bfbe02d

Browse files
penalosathomasgauvin
authored andcommitted
Add debug terminals changelog (#23454)
* Add debug terminals changelog * Address comments
1 parent 89f33ba commit bfbe02d

File tree

2 files changed

+30
-15
lines changed

2 files changed

+30
-15
lines changed
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
---
2+
title: Workers now supports JavaScript debug terminals in VSCode, Cursor and Windsurf IDEs
3+
description: Wrangler, the Cloudflare Vite plugin, and Miniflare now support breakpoint debugging via JavaScript debug terminals in VSCode
4+
products:
5+
- workers
6+
date: 2025-07-04T01:00:00Z
7+
---
8+
9+
Workers now support breakpoint debugging using VSCode's built-in [JavaScript Debug Terminals](https://code.visualstudio.com/docs/nodejs/nodejs-debugging#_javascript-debug-terminal). All you have to do is open a JS debug terminal (`Cmd + Shift + P` and then type `javascript debug`) and run `wrangler dev` (or `vite dev`) from within the debug terminal. VSCode will automatically connect to your running Worker (even if you're running multiple Workers at once!) and start a debugging session.
10+
11+
In 2023 we announced [breakpoint debugging support](https://blog.cloudflare.com/debugging-cloudflare-workers/) for Workers, which meant that you could easily debug your Worker code in Wrangler's built-in devtools (accessible via the `[d]` hotkey) as well as multiple other devtools clients, [including VSCode](https://developers.cloudflare.com/workers/observability/dev-tools/breakpoints/). For most developers, breakpoint debugging via VSCode is the most natural flow, but until now it's required [manually configuring a `launch.json` file](https://developers.cloudflare.com/workers/observability/dev-tools/breakpoints/#setup-vs-code-to-use-breakpoints), running `wrangler dev`, and connecting via VSCode's built-in debugger. Now it's much more seamless!

src/content/docs/workers/observability/dev-tools/breakpoints.mdx

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,15 @@ head: []
99

1010
## Debug via breakpoints
1111

12-
As of Wrangler 3.9.0, you can debug via breakpoints in your Worker. Breakpoints provide the ability to review what is happening at a given point in the execution of your Worker. Breakpoint functionality exists in both DevTools and VS Code.
12+
When developing a Worker locally using Wrangler or Vite, you can debug via breakpoints in your Worker. Breakpoints provide the ability to review what is happening at a given point in the execution of your Worker. Breakpoint functionality exists in both DevTools and VS Code.
1313

1414
For more information on breakpoint debugging via Chrome's DevTools, refer to [Chrome's article on breakpoints](https://developer.chrome.com/docs/devtools/javascript/breakpoints/).
1515

16-
### Setup VS Code to use breakpoints
16+
### VSCode debug terminals
17+
18+
Using VSCode's built-in [JavaScript Debug Terminals](https://code.visualstudio.com/docs/nodejs/nodejs-debugging#_javascript-debug-terminal), all you have to do is open a JS debug terminal (`Cmd + Shift + P` and then type `javascript debug`) and run `wrangler dev` (or `vite dev`) from within the debug terminal. VSCode will automatically connect to your running Worker (even if you're running multiple Workers at once!) and start a debugging session.
19+
20+
### Setup VS Code to use breakpoints with `launch.json` files
1721

1822
To setup VS Code for breakpoint debugging in your Worker project:
1923

@@ -22,19 +26,19 @@ To setup VS Code for breakpoint debugging in your Worker project:
2226

2327
```json
2428
{
25-
"configurations": [
26-
{
27-
"name": "Wrangler",
28-
"type": "node",
29-
"request": "attach",
30-
"port": 9229,
31-
"cwd": "/",
32-
"resolveSourceMapLocations": null,
33-
"attachExistingChildren": false,
34-
"autoAttachChildProcesses": false,
35-
"sourceMaps": true // works with or without this line
36-
}
37-
]
29+
"configurations": [
30+
{
31+
"name": "Wrangler",
32+
"type": "node",
33+
"request": "attach",
34+
"port": 9229,
35+
"cwd": "/",
36+
"resolveSourceMapLocations": null,
37+
"attachExistingChildren": false,
38+
"autoAttachChildProcesses": false,
39+
"sourceMaps": true // works with or without this line
40+
}
41+
]
3842
}
3943
```
4044

0 commit comments

Comments
 (0)