{"by":"kelvinzhang","descendants":89,"id":39027543,"kids":[39028540,39029943,39030136,39028266,39028603,39031052,39029434,39032178,39034297,39031764,39029642,39028746,39032305,39031012,39030941,39029135,39030288,39030414,39034141,39037882,39034631,39028653,39037467,39038041,39033947,39028897,39029395,39038278,39032004,39028408,39034909,39032419,39030346,39028647,39030432,39032654,39028652,39032894,39030255,39027544],"score":226,"text":"htmldocs is an Overleaf-style editor for typesetting documents using HTML&#x2F;CSS, which provides the same benefits as LaTeX while being more accessible, customizable, and familiar.<p>I built this because I wanted to programatically generate invoices as well as automatically tailor my resume to jobs but had no good way of generating well-formatted PDFs. I ended up building a templating engine to Chromium rendering pipeline to generate PDFs, and due to the amount of engineering effort, turned it into a tool for others that might want to do the same. There&#x27;s a built-in API (<a href=\"https:&#x2F;&#x2F;htmldocs.com&#x2F;docs&#x2F;documents\" rel=\"nofollow\">https:&#x2F;&#x2F;htmldocs.com&#x2F;docs&#x2F;documents</a>) that you can call to turn JSON into PDFs in a single call.<p>htmldocs is different from other tools like Wkhtmltopdf and Weasyprint in that it uses Chromium to generate PDFs, meaning that it supports the most modern CSS features and there&#x27;s minimal drift between the rendered HTML document and PDF.<p>Will also consider open sourcing if there&#x27;s enough interest in the project!","time":1705499041,"title":"Show HN: Htmldocs – Typeset and generate pdfs with HTML/CSS","type":"story","url":"https://htmldocs.com"}