Analysis updated 2026-05-18
Convert a long webpage into a multi-page PDF with selectable text.
Add repeating headers and footers to exported documents.
Embed custom fonts so non-English text renders correctly in the PDF.
Generate password protected, encrypted PDF files entirely client side.
| lmn1919/dompdf.js | f/git-rewrite-commits | openkursar/hello-halo | |
|---|---|---|---|
| Stars | 1,408 | 1,411 | 1,423 |
| Language | TypeScript | TypeScript | TypeScript |
| Setup difficulty | easy | easy | easy |
| Complexity | 2/5 | 2/5 | 3/5 |
| Audience | developer | developer | pm founder |
Figures from each repo's GitHub metadata at analysis time.
Local development requires Node.js 18+ and the Rust toolchain with the wasm32-unknown-unknown target.
dompdf.js is a JavaScript library that turns a webpage or part of a webpage into a PDF file, entirely inside the user's browser. Unlike many similar tools, it does not rely on the popular jsPDF library or on taking a screenshot of the page. Instead it uses Rust code compiled to WebAssembly to build a real vector PDF, meaning the text stays sharp at any zoom level and can be selected and copied, rather than being a flat image. The tool is aimed at long documents that need to be split across many pages, and it supports things like custom font embedding for non-English text, repeating headers and footers on every page, PDF compression, and password protection through encryption. Because everything runs in the browser, no server is needed to generate the file. Using it is meant to be simple: you point it at an element on the page, optionally turn on pagination and set a paper size, and it hands back a PDF file as a downloadable blob. Behind the scenes, the main part of the page is scanned, the work of preparing the render data is handed off to a background web worker so the page interface does not freeze, and the Rust based WebAssembly module writes the final PDF bytes. The project keeps a small number of options from an older, jsPDF based version of the tool for the sake of easier upgrades, though those specific options are accepted without actually doing anything in the new version. Setting it up locally requires Node.js and the Rust programming toolchain, since part of the project is compiled from Rust into WebAssembly during the build. The project is released under the MIT license, a permissive license that allows free use, including commercial use, as long as the copyright notice is kept.
A browser based library that converts web pages into real vector PDFs using Rust and WebAssembly, without needing a server.
Mainly TypeScript. The stack also includes TypeScript, Rust, WebAssembly.
Use freely for any purpose, including commercial use, as long as you keep the copyright notice.
Setup difficulty is rated easy, with roughly 5min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
Verify against the repo before relying on details.