简体   繁体   English

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

[英]How to hide a debug action in code editor

Is it possible to hide the following "Debug" link between 9 and 10 lines?是否可以在第 9 行和第 10 行之间隐藏以下“调试”链接?

代码中的调试链接

Either in Jest tests or in all code.无论是在 Jest 测试中还是在所有代码中。

These links are very annoying.这些链接非常烦人。 For example the file contains 20-50 tests.例如,该文件包含 20-50 个测试。 When I edit the file all these 20-50 links disappear.当我编辑文件时,所有这些 20-50 个链接都消失了。 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:)我因为这个万花筒而头疼:)

CodeLens shows the debug action. CodeLens 显示调试操作。 It can be customized for Jest using the following settings:可以使用以下设置为 Jest 自定义它:

    "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.如果将指定一个空的状态数组,那么该操作将始终隐藏。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM