VS code debugger variables not showing up

I am trying to debug a test in vscode. jest is runner. Here is my launch configuration.

{ "version": "0.2.0", "configurations": [ { "type": "node", "request": "launch", "name": "Jest All", "program": "${workspaceFolder}/node_modules/jest/bin/jest", "args": ["--runInBand"], "console": "integratedTerminal", "internalConsoleOptions": "neverOpen", "sourceMaps": true } ] } 

Using this when i launch the debugger it stops at breakpoint but none of the variables show up in local variable pane. image

1 Answer

Try this (if u are on windows):

{ "version": "0.2.0", "configurations": [ { "type": "node", "request": "launch", "name": "Jest All", "program": "${workspaceFolder}/node_modules/.bin/jest", "args": ["--runInBand"], "console": "integratedTerminal", "internalConsoleOptions": "neverOpen", "disableOptimisticBPs": true, "windows": { "program": "${workspaceFolder}/node_modules/jest/bin/jest", } }, { "type": "node", "request": "launch", "name": "Jest Current File", "program": "${workspaceFolder}/node_modules/.bin/jest", "args": [ "${fileBasenameNoExtension}", "--config", "jest.config.js" ], "console": "integratedTerminal", "internalConsoleOptions": "neverOpen", "disableOptimisticBPs": true, "windows": { "program": "${workspaceFolder}/node_modules/jest/bin/jest", } } ] } 
2

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like