vscode 快捷键侧边栏

_____ 配置 vscode 快捷键

visual studio code - open explorer and close sidebar with the same key - Stack Overflow

{

"key": "ctrl+shift+e", // when Explorer not open

// "command": "workbench.view.explorer", // either of these commands works

"command": "workbench.files.action.focusFilesExplorer",

"when": "!explorerViewletVisible"

},

{

"key": "ctrl+shift+e", // when Explorer open

"command": "workbench.action.toggleSidebarVisibility",

"when": "explorerViewletVisible"

}

How did I find those context keys? See Inspect Context Keys Utility.

  1. Open View/Help/Toggle Developer Tools

  2. Go to and clear (right-click) the Console in the Developer Tools

  3. Trigger the command: Developer: Inspect Context Keys from the Command Palette and click anywhere in the vscode window

  4. In the Console, a large object will be created and output. Expand this object open so you can search in it.

  5. With focus in the Console, Ctrl/Cmd+F to open a find input. For me, this appears at the very bottom and is tricky to see.

  6. Type what you want to find, like "explorer"

  7. I found 21 hits and looked at them all to see which were promising - you can Enter through them if focus is in the find input.

explorerViewletVisible looked most promising. Then I looked through the KeyBoard Shortcuts for "view explorer" and then "sidebar" to find commands I thought would work.

相关推荐
还有你Y6 小时前
VScode远程连接docker容器教程
ide·vscode·docker
Kaze-110 小时前
VSCode Copilot无法连接网络的解决过程
ide·vscode·copilot
屿筱10 小时前
vscode 关于C/C++的环境配置
c++·ide·vscode
2401_8534482319 小时前
K210环境搭建(VsCode)
vscode·踩坑·k210环境搭建
祎直向前20 小时前
重装Ubuntu之后重连VSCode
linux·vscode·ubuntu
我命由我1234521 小时前
VSCode - VSCode 修改文件树缩进
前端·ide·vscode·前端框架·编辑器·html·js
white-persist1 天前
VSCode 快捷键大全:从设计理念到场景化高效运用(详细解析)(文章末尾有vim快捷键大全)
linux·ide·vscode·python·编辑器·系统安全·vim
我命由我123451 天前
VSCode - VSCode 颜色值快速转换
前端·ide·vscode·前端框架·编辑器·html·js
BD_Marathon1 天前
【JavaWeb】VsCode中快速生成HTML5模板
ide·vscode·html5