pdf VS WeasyPrint

Compare pdf vs WeasyPrint and see what are their differences.

Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
pdf WeasyPrint
3 43
313 6,610
- 2.1%
0.0 9.4
over 2 years ago 7 days ago
JavaScript Python
MIT License BSD 3-clause "New" or "Revised" License
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

pdf

Posts with mentions or reviews of pdf. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2021-04-04.
  • Guide (and example code) to producing beautiful PDFs from CSS and JS
    1 project | /r/css | 6 Apr 2021
  • Beautiful PDFs from HTML
    13 projects | news.ycombinator.com | 4 Apr 2021
    Hi dang, hope you are well. May I kindly ask why not? I spent two weeks writing the CSS / HTML / JavaScript, and did well documented code - in fact the output serves as both documentation of the code and also output from it (in my own stupid way, I was thinking I was following Donald Knuth’s Literate Programming Approach :D).

    The repo (https://github.com/ashok-khanna/pdf) contains all the necessary code and is intended for others to reuse in their projects. Some of it isn’t straightforward, despite the guide looking easy - I had to figure out how CSS selectors and counters work for example, how MathJax interacted with Paged.Js.

    I think the confusion comes from it being labeled as a “guide”, in fact it’s a full set of code to give the required functionality for high quality PDFs from HTML, using paged.js, the guide is just the self documentation as I figured I might as well use documentation for the sample output. Otherwise, I’d be genuinely curious on what constitutes Show HN vs normal posts?

    I think the repo description and the way the output is confusing / unclear - the primary goal is very much meant to be a code base for people to reuse as I’ve noticed for many programmers, the design side can be a bit more elusive.

    Separately, would it be possible to add beautiful back to the title - it’s not really about producing PDFs from html as browsers can already do that, and there are many other tools. The main aim is to have the functionality to produce very high quality typeset PDFs from HTML, which until now, I only felt PrinceXML did well and that’s a paid solution. Maybe we could say the title is “High quality PDFs from HTML using Paged.JS”? I know there has been a separate discussion on another thread on the overuse of the word beautiful in describing code - my view is that it has its place when it relates to output / UI.

    Thanks for reading, and no issues otherwise (no need to reply).

WeasyPrint

Posts with mentions or reviews of WeasyPrint. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2024-03-11.

What are some alternatives?

When comparing pdf and WeasyPrint you can also consider the following projects:

asciidoctor-web-pdf - Convert AsciiDoc documents to PDF using web technologies

ReportLab

ReLaXed - Create PDF documents using web technologies

PyPDF2 - A pure-python PDF library capable of splitting, merging, cropping, and transforming the pages of PDF files

SingleFile - Web Extension for saving a faithful copy of a complete web page in a single HTML file

WKHTMLToPDF - Convert HTML to PDF using Webkit (QtWebKit)

breezy-pdf-lite - HTML/CSS/JS in, PDF out, via Chrome

QuestPDF - QuestPDF is a modern open-source .NET library for PDF document generation. Offering comprehensive layout engine powered by concise and discoverable C# Fluent API. Easily generate PDF reports, invoices, exports, etc.

MathJax - Beautiful and accessible math in all browsers

PDFMiner - Python PDF Parser (Not actively maintained). Check out pdfminer.six.

pagedown - Paginate the HTML Output of R Markdown with CSS for Print