Snippets do not respect user's indentation configuration.
See original GitHub issueSummary
I use 4 space hard tabs for indentation when working, so when I used the standard for
snippets i found it indented with 3 spaces.
Steps To Reproduce:
- Enable whitespace rendering in atom. (
ctrl+shift+p
->View: Toggle Render Whitespace
) - Change indentation to 4 space tabs or other indentation configuration other than 3 spaces.
- Insert any snippet that contains indentation. (Ex:
for
,while
,testMethod
,try
, etc.)
Expected result
The snippet should be inserted with the new indentation respecting the user’s configuration.
Actual result
The snippet is inserted with a three space indentation.
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
indent-region does not respect my c-mode style
It's awkward to have clangd auto-format with its default config, which looks vastly different, when what I wrote already looks like the correct ......
Read more >65293 – [formatting] Javadoc formatting: doesn't fully respect code ...
I did a complete Format of the file and just double-checked that it is indeed the code formatter which removes all the indentation....
Read more >Can you configure indentation for language server snippets to ...
BTW, yes, I'm using a light theme (don't know why either). EDIT: I'm thinking a possible solution was overriding the code actions handler,...
Read more >Inconsistency of indentation of tabs between markup editor / code ...
In Stack Snippets, a tab corresponds not with 4 but with 8 spaces. That makes it pretty difficult and tedious to properly indent...
Read more >Indentation Error in Python | How to Solve it - Edureka
Go to the setting of your code editor and enable the option which shows the tab and whitespaces. Once this feature in turned...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Actually you can, I wrote personal snippets, indented them with
\t
, tested them with multiple indentation configurations and found them working as expected.Example snippet
Shipped today.