When I hit alt+tab, VS code do auto save, and formats code, how to stop it?
Whenever I write some code and go to another tab by pressing alt+tab then VS Code auto saves the code and formats it. But I don't want this functionality. How to stop it?
When I hit alt+tab, VS code do auto save, and formats code, how to stop it?
Whenever I write some code and go to another tab by pressing alt+tab then VS Code auto saves the code and formats it. But I don't want this functionality. How to stop it?
hb20007
On
There was a bug in VS Code which caused AutoSave to trigger editor.formatOnSave even when files.autoSave is set to afterDelay.
The March 2024 release includes the fix for this bag (release date: 4 April 2024).
Copyright © 2021 Jogjafile Inc.

Pretty sure this could happen if you have the following combo of settings:
Just tinker with those settings (and the related ones) until you get what you want.
There might also be bugs with the feature, such as was found and fixed in issue ticket #206475, which looks like it might be the same issue you're having: when
files.autoSaveis set toafterDelayandeditor.formatOnSaveis set totrue,