✨ Add VS Code node:test debugging and runner config

launch.json: 'Debug current test file' F5 config running
node --test --strip-types on the active file.

settings.json: register .ts with the connor4312.nodejs-testing
extension via nodejs-testing.extensions, using --strip-types (the
repo pins node >=26 with native type stripping) instead of tsx, so
the extension discovers src/*.test.ts and shows Run/Debug lenses
above test() calls in the native Testing UI.

extensions.json: recommend connor4312.nodejs-testing; cspell.json:
allow 'connor' for the extension id.

.gitignore: un-ignore .vscode/launch.json so the config is shared.
This commit is contained in:
tmu committed 2026-09-16 17:34:53 +00:00
1 parent 62a5599ab3
commit 2ff67801e0
5 files changed
+30 -2

No files matched your search

+2 -1
View File
@@ -10,5 +10,6 @@ coverage
!.vscode/extensions.json
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
.idea
.DS_Store
.DS_Store
+1
View File
@@ -1,5 +1,6 @@
{
"recommendations": [
"connor4312.nodejs-testing",
"oxc.oxc-vscode",
"streetsidesoftware.code-spell-checker",
"typescriptteam.native-preview",
+15
View File
@@ -0,0 +1,15 @@
{
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Debug current test file",
"runtimeExecutable": "node",
"runtimeArgs": ["--test", "--strip-types"],
"args": ["${file}"],
"cwd": "${workspaceFolder}",
"console": "integratedTerminal"
}
]
}
+10
View File
@@ -1,4 +1,14 @@
{
"nodejs-testing.extensions": [
{
"extensions": ["mjs", "cjs", "js"],
"parameters": []
},
{
"extensions": ["ts"],
"parameters": ["--strip-types"]
}
],
"[typescript]": {
"editor.defaultFormatter": "oxc.oxc-vscode",
"editor.formatOnSave": true
+2 -1
View File
@@ -42,7 +42,8 @@
"bestikk",
"silverwind",
"idris",
"todotasks"
"todotasks",
"connor"
],
"ignorePaths": ["dist", "node_modules", "coverage", "*.svg", ".gitignore"]
}