I was trying to set up VSCode to be able to debug Gatsby code. I am new to Javascript sourcemaps which seem to be the cause of the problem.
I am seeing the following error on launch:
Cannot launch program "c:\Gatsby\myprogram\node_modules\.bin\gatsby" because corresponding Javascript cannot be found.
I verified that the path to the file gatsby in the error exists.
This is the file that I am using for launch.json:
  "version": "0.2.0",
  "configurations": [
    {
    "name": "Launch",
    "type": "node",
    "request": "launch",
    "protocol": "inspector",
    "program": "${workspaceRoot}/node_modules/.bin/gatsby",
    "args": ["develop", "-p", "7777"],
    "stopOnEntry": false,
    "cwd": "${workspaceRoot}",
    "preLaunchTask": null,
    "runtimeExecutable": null,
    "runtimeArgs": [
      "--nolazy"
    ],
    "env": {
      "NODE_ENV": "development",
      "DEBUG": "gatsby:*"
    },
    "console": "integratedTerminal",
    "sourceMaps": true,
    "outFiles": []
   }
  ]
}
 
     
    