It can be used for creating a PDF locally, or the HTML file can also be viewed directly in the browser - both should look identical.
When I was looking into different ways of converting HTML into PDF, everything I came across did a pretty bad job at correctly supporting CSS layouts and positioning. So I ended up just using headless Chrome for printing. Perhaps WeasyPrint does a better job with CSS support?
((−5(if the finnicky effort to even a decimal number found a different
Finnicky effort indeed ;)