How it formats
The formatter is Prettier, the most widely used code formatter, running in your browser. Each nested element goes on its own line and is indented; long attribute lists wrap; <style> and <script> contents are formatted as CSS and JavaScript.
Whitespace handling is set to “ignore”, which gives the tidiest result. If exact inline spacing matters (for example between two <span>s), check the rendered page after formatting.
Going the other way
To shrink HTML for production, use the HTML minifier.