mobilizon/priv/python/pdf.py

4 lines
105 B
Python

from weasyprint import HTML
def generate(html):
return HTML(string=html.decode('utf-8')).write_pdf()