问题标签 [vscode-debugger]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
visual-studio-code - VSCode dynamic processid in launch.json
right now my launch.json file for debugging looks like this
but the things is that I need to manually update the processid every time, is that possible that for the "processId", I can invoke some kind of script and return a pid in programmatic manner? ex. "processId": ${shell_script: get_pid}
visual-studio-code - How to use cpx when debugging in VS Code?
I want to use cpx as a background task for one of my debugging configurations inside Visual Studio Code. However it has no output and causes this error:
Since cpx does it's job in less then a second I don't need it to be tracked. Is there a way to tell VS Code just to run the task and not track it?
Here's my tasks.json
:
visual-studio-code - 使用 vscode 调试器时无法找到一些 node_modules 路径
我无法运行节点调试器。它显示以下错误。
当我尝试手动安装此模块时,我收到其他一些模块的错误。这些事情还在继续。
所有这些模块都不是直接依赖项。这些是我正在使用的包的内部依赖项。
当我直接用节点运行同一个项目(没有调试)时,它工作得很好。
当我使用与 vscode_insiders 相同的 launch.json(调试设置)运行相同的项目时,它运行良好。
我最近将 vscode 更新为 1.24.1。这有什么问题吗?
visual-studio-code - 为什么 vscode 中不存在 TreeDataProvider?
我按照这个链接https://code.visualstudio.com/docs/extensions/yocode在javascript
. 我想用来创建一个树视图,但是从模块TreeDataProvider
中找不到这个类。vscode
上面的代码返回undefined
到TreeDataProvider
. 下面是我的 package.json 依赖项:
有谁知道如何在 javascript 项目中要求这个类?
visual-studio-code - 在不同端口上使用 VS Code 调试 2 个 nodemon 实例
我目前正在开发一个完全使用 Node.js 的应用程序,因此有 2 个 nodemon 实例同时运行,client
并且server
:
所以这是 VS Code 中打开的目录。在scripts
两者的部分中,package.json
我有以下内容:
"dev": "nodemon --inspect ./index.js"
我对如何调试 nodemon 实例进行了一些研究,并在 VS Code 的存储库中找到了此配置:
但现在的问题是,当我同时运行这两个脚本时,我的终端出现以下错误:Starting inspector on 127.0.0.1:9229 failed: address already in use
是否可以在另一个端口上使用调试器?
node.js - 带有 webpack 和节点 js 的 VSCode 调试器 - 断点灰色 -> “断点已设置但尚未绑定”
新来的。我正在尝试为我的 node.js Web 应用程序配置 vscode 调试器。使用的技术是 node.js、webpack、pug 和普通的旧 js。我已经按照几个指南和步骤来尝试配置它,并且承认缺乏对不同部分的理解是这里的关键问题。
目标:使用 webpack 启动 localhost,并在服务器文件和前端文件中设置断点,这将有助于调试或至少告诉我在任何给定时间正在传输哪些变量。
问题:不断收到消息“断点已设置但尚未绑定”。
任何帮助将不胜感激!
下面是我用来运行它的粘贴文件和控制台输出 --> 使用的配置(这基本上是我尝试过的最新示例之一):
其次是服务器启动
typescript - 打字稿源文件中带有 ts-jest 断点的 vscode-jest
我有一个 TypeScript 项目,并且正在通过ts-jest使用 Jest 进行测试。在 VS Code 中,我安装了插件vscode-jest。调试并不像我想要的那样工作:
- 我可以通过单击
Debug
vscode-jest 生成的 CodeLens来启动调试会话 - 如果我在测试代码中放置断点,调试器将按预期在断点处暂停
- 但是如果我在源代码中设置断点,调试器会忽略它
我想这是因为 ts-jest 的工作方式。可能永远找不到断点,因为测试是在 JS 文件而不是 TS 文件上运行的。
如果我在使用 Create React App 引导的 JS 项目中尝试相同的操作,我可以在源文件中设置断点,调试器将停止。这很有趣,因为这些源文件也正在由 babel 编译......
我想知道是否可以调整我的设置,以便调试器识别源文件中的断点。
在下面发布一些可能相关的文件:
jest.config.js
tsconfig.json
visual-studio-code - VScode 停止使用 ElixirLS 插件,系统冻结。LinuxMint 机器
先前的问题:如何为 Elixir 的系统范围使用设置路径并为 ElixirLS 配置 VScode? 问题更新
我使用本教程在我的 Linuxmint 机器上安装了 Elixir。 https://gist.github.com/emerleite/6d44f64d2a5b6be933c0b533234f1c88
已解决:但我每次都必须在我的 shell $ 上运行。.bash_profile 启动 exenv 以加载长生不老药。如何使其成为系统范围或设置路径,以便我可以触发 iex 而无需每次调用 at shell $。.bash_profile。
当我打开 VSCode 并安装了 Elixir-Ls https://github.com/JakeBecker/vscode-elixir-ls插件时,我的系统就死机了。我不能点击任何东西。VSCode 显示一条弹出消息
“无法运行“elixir”命令 ElixirLs 可能无法启动
" 请帮助如何让 ElixirLs 在 Visual Studio 中正常工作。我什至尝试使用 "asdf" 但不适用于 Vscode。