unpdf
JSON →unpdf is a modern, actively maintained PDF extraction and rendering library that runs across all JavaScript runtimes: Node.js, Deno, Bun, browsers, and serverless environments like Cloudflare Workers. Version 1.6.2 ships a serverless build of Mozilla's PDF.js v5.6.205, optimized for edge computing. It provides high-level APIs for extracting text, links, and images from PDF files, making it ideal for AI applications that require PDF summarization or analysis. Unlike older libraries like pdf-parse, unpdf supports ESM, TypeScript natively, and eliminates the need for external worker files in serverless contexts. It offers opt-in support for official or legacy PDF.js builds and includes a peer dependency on @napi-rs/canvas for rendering operations.