You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I recently rewrote the Razor formatter, and one of the benefits of the new one is that this problem should be solved. If you're using VS 17.14 preview then you should already have the new formatting engine, so would be good to confirm.
Hi @davidwengier indeed I have VS Preview as well. Looks like the endless indention has been fixed here. However there are still some formatting issues here. The semicolon will trigger the first one to move a tab and all items within will also move one indention. Please see this video:
Glad to hear it! The semi colon thing is #11488 and that bit happens to still use the old formatter, but that's not why it's broken, just an odd coincidence.
Actually, now that I have a slightly bigger screen to watch on, I think the moving of the initial square bracket is probably not fixed by #11488 but will be fixed when on type formatting gets moved to the new formatter. Will leave this issue open to track that I think
MarvinKlein1508
changed the title
Razor editos messes up indention of collection initializers when formatting the document
Razor editor messes up indention of collection initializers when formatting the document
Feb 17, 2025
When using collection initializers the formatting will be messed up everytime you format the document using
CTRL+K,D
Please see this small video for details:
https://github.com/user-attachments/assets/6bbd5fff-7f39-4118-9f35-6a160317783a
The text was updated successfully, but these errors were encountered: