DEV Community

Shivam Singhal
Shivam Singhal

Posted on • Originally published at itsopensource.com

How to always keep files open in Visual Studio Code

Visual Code is an amazing editor and I use it for my everyday code. One thing bugs me every time is the files are not open permanently until I use the shortcut cmd + k enter or right-click and select keep open on the filename. This happens because the VS Code opens the files by default in preview mode, so whenever the new file name is clicked from explorer, the opened file closes and the new file is visible. But if you are equally frustrated by this behavior here is what you need to do.

The solution is way simpler than expected, just add the following line to your setting.json
(Code Menu > Preferences > Setting)

"workbench.editor.enablePreview": false

Follow me on GitHub and Twitter

Cheers!

Top comments (0)