Skip to content

VS Code — Disable Auto Save when Errors

VS Code Disable Auto Save when Errors

In this post, we will explore a new VS Code setting that allows you to disable Auto Save when errors are detected in the file.

This feature can be useful in situations where external tools are monitoring the file and you want to avoid these tools to act on files that contain errors.

How to enable the feature

Press CTRL + , (comma) and search for “auto save errors“.

Then tick the Files: Auto Save When No Errors checkbox.

This setting only applies when Files: Auto Save is enabled.

You can also enable or disable the Files: Auto Save When No Errors setting via your settings.json file:

"files.autoSaveWhenNoErrors": true

🎥 Prefer a video instead?


Let me know what you think about this article in the comments section below.

If you find this article helpful, please share it with others and subscribe to the blog to support me, and receive a bi-monthly-ish e-mail notification on my latest articles.   
  

Comments