Hi, I created the invoicing SaaS iFacture
Currently, PDF documents (invoices and quotes) are generated using code + iTextSharp. This executes very fast but this is not easy to modify.
So, for the new version I want to use ServiceStack + Puppeteer Sharp to generate PDF from a Razor view (.cshtml).
The idea is to have the Razor view inside ServiceInterface project (embedded resource?) (and not on the web project) and pass a populated model during execution to be able to render the HTML View. Since I want to populate the HTML file directly from the model, I don’t need things like relative path or absolute URIs…
After that, Puppeteer Sharp will transform the HTML rendered view in PDF. It’s slower but easier to change.
A project like RazorEngine could do the trick, but it is not maintained anymore and maybe I can do that with ServiceStack Razor.
I am using Framework 6.
How would you do this?
Thank you in advance.