如何在代码编辑器中隐藏调试动作

发布于 2025-01-31 21:07:16 字数 342 浏览 2 评论 0原文

是否可以在9和10行之间隐藏以下“调试”链接?

在Jest测试中或在所有代码中。

这些链接非常烦人。例如,该文件包含20-50个测试。当我编辑文件时,所有这些20-50个链接都会消失。当我保存文件时,再次添加链接。在每个编辑/保存迭代上,所有行都会移动。由于这个万花筒,我头疼:)

Is it possible to hide the following "Debug" link between 9 and 10 lines?

debug link in code

Either in Jest tests or in all code.

These links are very annoying. For example the file contains 20-50 tests. When I edit the file all these 20-50 links disappear. And when I save the file the links are added again. On each edit/save iteration all lines are shifted. I have a headache because of this kaleidoscope :)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

傾旎 2025-02-07 21:07:16

Codelens显示了调试动作。它可以使用以下设置为开玩笑定制:

    "jest.debugCodeLens.showWhenTestStateIn": [
        "fail"
    ]

只有在测试失败时才显示操作。如果有人指定一个空状态,则该操作将始终隐藏。

CodeLens shows the debug action. It can be customized for Jest using the following settings:

    "jest.debugCodeLens.showWhenTestStateIn": [
        "fail"
    ]

The action will be shown only if a test was failed. If one will specify an empty array of states, then the action will be always hidden.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文