bagasprstyadi
Elixir PDF Generator Failed to Render the String of HTML
Hi, I have a problem when creating PDF using elixir-pdf-generator from this library GitHub - gutschilla/elixir-pdf-generator: Create PDFs with wkhtmltopdf or puppeteer/chromium from Elixir. · GitHub
Basically I already followed all the instruction and use the wkhtmltopdf. When I tried to create it using the example.
PdfGenerator.generate {:url, "http://google.com"}, page_size: "A5"
What I get is a PDF that is the page of google but all the string are blank (failed to render)
Can anyone help me? I’m currently stuck here
This also happened when I create using the html stirng from my local device.
Most Liked
maltoe
Not really on topic, but:
Last time I looked into it, wkhtmltopdf didn’t look like a healthy project very much: still using ancient QtWebkit, not much development happening, etc. They have a pretty good writeup on the library’s status on their homepage wkhtmltopdf, which didn’t exactly makes you want to start using it for new projects either. I can only recommend switching to a recent Chrome/Chromium as your rendering engine, if you can. There are a few libraries in Elixir-land that have support for it, and it might solve your rendering issues as well.
olivermt
tessi
This blog post gives a little more insight on different PDF printers from a performance perspective:
It seems that ChromicPDF is up to 60 times faster for small PDFs than pdf_generator (and even faster compared to pupeteer_pdf).
Popular in Questions
Other popular topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #elixirconf-us
- #advent-of-code
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #hex










