Open DanielJackson-Oslo opened 4 years ago
No I haven't, JSON is currently somewhat easier format to structure around. We could try to have some inline elements like anchors or other formatting tags in Paragraph elements..
I did some research, and seems like wkhtmltopdf and all other html + css readers are too complex for wasm, as f.ex. wkthmltopdf includes all of Qt. :(
My usecase is to generate PDFs from HTML emails. Easy to do backend, but I'd like to do it client side for privacy and security reasons.
If you need to reproduce the actual appearance of the email, then it will be pretty difficult at the moment. You'd essentially need a browser in browser to provide layout, styles etc.
But if all emails look the same then you could propably "hardcode" styling into WASM output..
@DanielJackson-Oslo I'm trying to do something similar. This is a great project. I really like the idea of implementing a pdf library in Rust for WASM and I really appreciate your effort @jussiniinikoski, but IMHO pdfmake seems like the next best option.
If Qt apps, QML browser or PC emulators can run in WASM, why couldn't a headless web engine be ported to WASM? Maybe port litehtml or lexbor to WASM and integrate with WASM-PDF?
Hi!
Have you attempted integrating something like https://wkhtmltopdf.org/ for full HTML support?