Skip to content
Advertisement

Tag: pdfkit

Python + pdfkit: Generate stream with pdfkit

I’m trying to use pdfkit to turn html pages into PDFs, and then return a stream of that PDF as this code is a Flask API called by a webpage. As far as I can tell, when you use pdfkit.from_file, you have provide both an input and output path: The problem is, I don’t want to write these files to

Why PDFKit doesn’t work well with margins?

although I just don’t have the need to ask something normally (internet is just a gold mine, especially this site), this is getting me off, as I had been two days trying to get this working and I don’t find anything useful. Link for similar post would be thanked if founded, as I didn’t found one. Let’s get started. I’m

Advertisement