{"id":13681733,"url":"https://github.com/mxsdev/nvim-dap-vscode-js","last_synced_at":"2026-01-15T01:32:55.014Z","repository":{"id":44097959,"uuid":"511750457","full_name":"mxsdev/nvim-dap-vscode-js","owner":"mxsdev","description":"nvim-dap adapter for vscode-js-debug","archived":false,"fork":false,"pushed_at":"2023-10-18T22:51:20.000Z","size":118,"stargazers_count":301,"open_issues_count":40,"forks_count":38,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-04-30T06:39:37.619Z","etag":null,"topics":["chrome","debug-adapter-protocol","msedge","neovim","nodejs","vscode"],"latest_commit_sha":null,"homepage":"","language":"Lua","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mxsdev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2022-07-08T03:34:24.000Z","updated_at":"2025-04-08T18:58:52.000Z","dependencies_parsed_at":"2024-01-14T15:38:13.664Z","dependency_job_id":null,"html_url":"https://github.com/mxsdev/nvim-dap-vscode-js","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/mxsdev/nvim-dap-vscode-js","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mxsdev%2Fnvim-dap-vscode-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mxsdev%2Fnvim-dap-vscode-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mxsdev%2Fnvim-dap-vscode-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mxsdev%2Fnvim-dap-vscode-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mxsdev","download_url":"https://codeload.github.com/mxsdev/nvim-dap-vscode-js/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mxsdev%2Fnvim-dap-vscode-js/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28441031,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-15T00:55:22.719Z","status":"ssl_error","status_checked_at":"2026-01-15T00:55:20.945Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chrome","debug-adapter-protocol","msedge","neovim","nodejs","vscode"],"created_at":"2024-08-02T13:01:35.090Z","updated_at":"2026-01-15T01:32:54.981Z","avatar_url":"https://github.com/mxsdev.png","language":"Lua","funding_links":[],"categories":["Lua"],"sub_categories":[],"readme":"# nvim-dap-vscode-js\n\n[nvim-dap](https://github.com/mfussenegger/nvim-dap) adapter for [vscode-js-debug](https://github.com/microsoft/vscode-js-debug). \n\n## Adapters\n\nEvery platform supported by vscode is provided. This includes:\n\n| Adapter             | Platform          | Support     |\n|---------------------|-------------------|-------------|\n| `pwa-node`          | Node.js           | Full        |\n| `pwa-chrome`        | Chrome            | Partial[^1] |\n| `pwa-msedge`        | Edge              | Untested    |\n| `node-terminal`     | Node.js           | Untested    |\n| `pwa-extensionHost` | VSCode Extensions | Untested    |\n\n## Installation\n\n### Plugin\n\nSupports packer, vim-plug, etc. With packer, for example:\n\n```lua\nuse { \"mxsdev/nvim-dap-vscode-js\", requires = {\"mfussenegger/nvim-dap\"} }\n```\n\n### Debugger\n\nYou must download and build a copy of [vscode-js-debug](https://github.com/microsoft/vscode-js-debug) in order to use this plugin. \n\n#### With Packer\n\n```lua\nuse {\n  \"microsoft/vscode-js-debug\",\n  opt = true,\n  run = \"npm install --legacy-peer-deps \u0026\u0026 npx gulp vsDebugServerBundle \u0026\u0026 mv dist out\" \n}\n```\n\n#### Manually\n\n```bash\ngit clone https://github.com/microsoft/vscode-js-debug\ncd vscode-js-debug\nnpm install --legacy-peer-deps\nnpx gulp vsDebugServerBundle\nmv dist out\n```\n\n\u003e **Note**: The upstream build process has changed sometime since the creation of this repo. If the above scripts don't work, please make sure you're using the latest version of `vscode-js-debug`. Otherwise, feel free to file an issue!\n\n## Setup\n\n```lua\nrequire(\"dap-vscode-js\").setup({\n  -- node_path = \"node\", -- Path of node executable. Defaults to $NODE_PATH, and then \"node\"\n  -- debugger_path = \"(runtimedir)/site/pack/packer/opt/vscode-js-debug\", -- Path to vscode-js-debug installation.\n  -- debugger_cmd = { \"js-debug-adapter\" }, -- Command to use to launch the debug server. Takes precedence over `node_path` and `debugger_path`.\n  adapters = { 'pwa-node', 'pwa-chrome', 'pwa-msedge', 'node-terminal', 'pwa-extensionHost' }, -- which adapters to register in nvim-dap\n  -- log_file_path = \"(stdpath cache)/dap_vscode_js.log\" -- Path for file logging\n  -- log_file_level = false -- Logging level for output to file. Set to false to disable file logging.\n  -- log_console_level = vim.log.levels.ERROR -- Logging level for output to console. Set to false to disable console output.\n})\n\nfor _, language in ipairs({ \"typescript\", \"javascript\" }) do\n  require(\"dap\").configurations[language] = {\n    ... -- see below\n  }\nend\n```\n\nNote that if vscode-js-debug was installed without packer, its root folder location must be set manually in `debugger_path`.\n\n### Configurations\n\nSee [here](https://github.com/microsoft/vscode-js-debug/blob/main/OPTIONS.md) for all custom configuration options.\n\n#### Node.js\n\n```lua\n{\n  {\n    type = \"pwa-node\",\n    request = \"launch\",\n    name = \"Launch file\",\n    program = \"${file}\",\n    cwd = \"${workspaceFolder}\",\n  },\n  {\n    type = \"pwa-node\",\n    request = \"attach\",\n    name = \"Attach\",\n    processId = require'dap.utils'.pick_process,\n    cwd = \"${workspaceFolder}\",\n  }\n}\n```\n\n#### Jest[^2]\n\n```lua\n{\n  {\n    type = \"pwa-node\",\n    request = \"launch\",\n    name = \"Debug Jest Tests\",\n    -- trace = true, -- include debugger info\n    runtimeExecutable = \"node\",\n    runtimeArgs = {\n      \"./node_modules/jest/bin/jest.js\",\n      \"--runInBand\",\n    },\n    rootPath = \"${workspaceFolder}\",\n    cwd = \"${workspaceFolder}\",\n    console = \"integratedTerminal\",\n    internalConsoleOptions = \"neverOpen\",\n  }\n}\n```\n\nYou may also want to check out [neotest-jest](https://github.com/haydenmeade/neotest-jest), which supports this plugin out of the box.\n\n#### Mocha\n\n```lua\n{\n  {\n    type = \"pwa-node\",\n    request = \"launch\",\n    name = \"Debug Mocha Tests\",\n    -- trace = true, -- include debugger info\n    runtimeExecutable = \"node\",\n    runtimeArgs = {\n      \"./node_modules/mocha/bin/mocha.js\",\n    },\n    rootPath = \"${workspaceFolder}\",\n    cwd = \"${workspaceFolder}\",\n    console = \"integratedTerminal\",\n    internalConsoleOptions = \"neverOpen\",\n  }\n}\n```\n\n## Planned Features\n\n - [ ] Integration with [neotest-jest](https://github.com/haydenmeade/neotest-jest)\n - [ ] Support for switching between child sessions\n\n## Credits\n\nI would like to say a huge thank you to [Jens Claes](https://github.com/entropitor), whose dotfiles this plugin is based off of, and to all members who contributed to [this issue](https://github.com/microsoft/vscode-js-debug/issues/902) - the insight gained from this was paramount to the success of this project.\n\n[^1]: The debugger runs and attaches, however breakpoints may be rejected.\n[^2]: See [here](https://github.com/microsoft/vscode-js-debug/issues/214#issuecomment-572686921) for more details on running jest\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmxsdev%2Fnvim-dap-vscode-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmxsdev%2Fnvim-dap-vscode-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmxsdev%2Fnvim-dap-vscode-js/lists"}