Reputation: 31
So I've recently started editing my userChrome.css in Waterfox, and VS Code is my code editor of choice. I'm completely new to CSS, so I may just be ignorant of formatting conventions, but whenever I save my file, VS Code adds an indent to every single line, including the very first one. If I save again, it adds another indent to every line (standard Tab - 4 spaces).
Is this the accepted standard for formatting? If so, I guess I'll just grin and bear it, but frankly it's rage inducing. It also keeps removing the empty lines I'm trying to put in before and after comments ( the /* comment here */
stuff ) to make the code more me-readable. I guess I can live with that, but the adding indents every time I save is making me crazy.
I tried searching for a solution, but I couldn't find one. If this is covered somewhere else, please let me know, and I'm sorry for wasting everyone's time.
Upvotes: 3
Views: 369
Reputation: 10520
This is probably related to your linter setting and not the VSCode itself. So to fix it first you should find the exact extension that caused this reformat then by accessing its settings via:
Extension tab > Extension (Extension name e.g: prettier) > Extension gear Icon (manage)
You can change your desired setting and when to invoke those settings.
NOTE: For more information you can read this.
Upvotes: 1