如何添加上下文菜单? (在资源管理器和/或编辑器中)
我尝试了以下不起作用:
constexpr
这是基于:
答案 0 :(得分:6)
extensionAPI文档有一个工作示例:https://code.visualstudio.com/docs/extensionAPI/extension-points
"contributes": {
"commands": [
{
"command": "extension.sayHello",
"title": "Say Hello"
}
],
"menus": {
"explorer/context": [{
"when": "resourceLangId == javascript",
"command": "extension.sayHello",
"group": "YourGroup@1"
}]
}
},