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.

相关推荐
lxmyzzs7 小时前
vscode-ssh无法进入docker问题解决
vscode·docker·ssh
Candice_jy7 小时前
vscode运行ipynb文件:使用docker中的虚拟环境
服务器·ide·vscode·python·docker·容器·编辑器
不染尘.9 小时前
2025_11_5_刷题
开发语言·c++·vscode·算法·贪心算法·动态规划
willhuo16 小时前
vscode编辑arduino项目
ide·vscode·编辑器
York·Zhang17 小时前
VSCode 插件开发完整指南:从零到发布
ide·vscode·node.js·编辑器
HealthScience1 天前
vscode默认使用typora打开md(Markdown)文件、vscode中打开Markdown怎么默认使用typora打开
ide·vscode·编辑器
脑子不好的小菜鸟1 天前
用vscode连接远端ubuntu无法git push,vscode无法连接centos
git·vscode·ubuntu·centos
それども1 天前
2025 Vscode安装Python教程
ide·vscode·编辑器
咯哦哦哦哦1 天前
vscode clangd 插件第三方库头文件不识别
ide·vscode·编辑器