Overview of pdf-lib features
masterpdf-lib is a library for creating and modifying PDF documents in any modern JavaScript runtime, including Node, Browser, Deno, and React Native.
Key capabilities include:
- Document Manipulation: Create new PDFs, modify existing ones, add, insert, or remove pages, and copy pages between documents.
- Form Handling: Create, fill, and flatten PDF forms.
- Drawing & Content: Draw text, images (PNG/JPEG), PDF pages, vector graphics, and SVG paths. It also supports measuring text width and height.
- Fonts: Embed fonts with support for UTF-8 and UTF-16 character sets.
- Metadata & Preferences: Set and read document metadata and viewer preferences.
- Attachments: Add attachments to PDF documents.