如何禁用 visual studio 代码中的信息框

How to disable info box in visual studio code

快速提问,我似乎无法正确猜出这个 "info box" 的名称,所以 google 找不到禁用它的正确解决方案。

它在 VSCode 术语中称为 Intellisense,您可以使用 settings.json 文件中的这些设置对其进行相应配置

转到文件 -> 首选项 -> 设置

搜索并单击“在 settings.json 中编辑”

    // Controls if quick suggestions should show up or not while typing
    "editor.quickSuggestions": false,

    // Enables parameter hints
    "editor.parameterHints": false,

    // Controls if suggestions should automatically show up when typing trigger characters
    "editor.suggestOnTriggerCharacters": false,

如果您在禁用这些功能后仍想访问这些功能,您可以使用键盘快捷键。

CTRL+SPACE - 触发建议

CTRL+SHIFT+SPACE - 触发参数命中数