VS Code and VS have different Html formatters, and that can cause problems for us as we try to adapt our formatter to be able to handle anything that is thrown at it. We should stop doing this, and rather be opinionated about the formatting of Html in Razor files and just handle it ourselves. The Razor compiler already has all of the smarts to parse the Html, and creates a tree we can work with, etc.
This would help us fix bugs like #11647 (comment), which we currently can either choose to have work in VS or VS Code, but not both, and we could add more options to our formatter to satisfy user requests like #11914 or #6551, both of which ask for more aggressive or opinionated attribute formatting.
Worth noting we'd still need to call the IDE built in formatter for attribute content, JavaScript, CSS etc. so it is really just the start-of-line indentation we'd be taking over.
VS Code and VS have different Html formatters, and that can cause problems for us as we try to adapt our formatter to be able to handle anything that is thrown at it. We should stop doing this, and rather be opinionated about the formatting of Html in Razor files and just handle it ourselves. The Razor compiler already has all of the smarts to parse the Html, and creates a tree we can work with, etc.
This would help us fix bugs like #11647 (comment), which we currently can either choose to have work in VS or VS Code, but not both, and we could add more options to our formatter to satisfy user requests like #11914 or #6551, both of which ask for more aggressive or opinionated attribute formatting.
Worth noting we'd still need to call the IDE built in formatter for attribute content, JavaScript, CSS etc. so it is really just the start-of-line indentation we'd be taking over.