I want VSCode to have only a single file tab (editor) at a time. When I switch files VSCode should replace the opened file with a new one instead of creating a new tab (editor) for it.
"workbench.editor.showTabs": false makes it so that there is only 1 tab visible. This is exactly how I want things to look like, but under the hood VSCode still creates a new tab for each file. You can see them if you set this parameter back to true or try to cycle through tabs with Ctrl+Tab.
There are these 3 settings that do exactly what I want to achieve:
// Disable tabs visually
"workbench.editor.showTabs": false,
// Enable the limit for number of opened tabs
"workbench.editor.limit.enabled": true,
// Set max amount of opened tabs. Older tabs will be closed
"workbench.editor.limit.value": 1,
There is also an extension called zentabs but has some flaws and is pretty much obsolete since what it does can be achieved natively.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With