Reputation: 195
In Microsoft VS Code when I'm closing HTML tag (e.g. on bottom image), current position will be moved to the first column and remove tabs indent. Then I need to indent manually with tabs again. How can I fix it?
My settings.json file:
... "editor.detectIndentation": false, "editor.wrappingIndent": "none", "editor.trimAutoWhitespace": false, "files.trimTrailingWhitespace": false, "files.insertFinalNewline": true, "html.format.endWithNewline": false, ...
Upvotes: 4
Views: 2238
Reputation: 195
I set the options in settings.json
to:
"editor.detectIndentation": true, "editor.autoIndent": false
And it's working now. Fixed.
Upvotes: 9
Reputation: 6832
In your settings.json
, "editor.detectIndentation": false
, is your issue. Make that true
.
i.e.
...
"editor.detectIndentation": true,
"editor.wrappingIndent": "none",
"editor.trimAutoWhitespace": false,
"files.trimTrailingWhitespace": false,
"files.insertFinalNewline": true,
"html.format.endWithNewline": false,
...
Upvotes: 2