Skip to content

Commit 96ee4f1

Browse files
bteahi-ogawabluwy
authored
docs: add vscode debug error situation description (#19631)
Co-authored-by: Hiroshi Ogawa <hi.ogawa.zz@gmail.com> Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>
1 parent 98b3160 commit 96ee4f1

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

docs/config/index.md

+16
Original file line numberDiff line numberDiff line change
@@ -121,3 +121,19 @@ export default defineConfig(({ mode }) => {
121121
}
122122
})
123123
```
124+
125+
## Debugging the Config File on VS Code
126+
127+
With the default `--configLoader bundle` behavior, Vite writes the generated temporary configuration file to the `node_modules/.vite-temp` folder and a file not found error will occur when setting breakpoint debugging in the Vite config file. To fix the issue, add the following configuration to `.vscode/settings.json`:
128+
129+
```json
130+
{
131+
"debug.javascript.terminalOptions": {
132+
"resolveSourceMapLocations": [
133+
"${workspaceFolder}/**",
134+
"!**/node_modules/**",
135+
"**/node_modules/.vite-temp/**"
136+
]
137+
}
138+
}
139+
```

0 commit comments

Comments
 (0)