libpdf-js/core ? reverse-engineered prompt
Reverse engineered prompt
Build me a modern TypeScript PDF library that can open messy real world PDFs, let me read and change pages, fill out forms, merge and split files, add attachments, and create new PDFs from scratch. I want a simple API that feels easy to use, with both high level helpers for common tasks and lower level objects for more control when needed.
It should also support encrypted PDFs, text extraction with positions, drawing text and shapes on pages, embedding fonts and images, and saving changes incrementally so signatures can be preserved. Please include digital signing support too, especially the common signing flow with a certificate file and password.
Make sure it works in Node, Bun, and modern browsers, and add a few good examples and tests so I can see how to use it right away. If you need to check current docs or PDF behavior online, feel free to look them up.
Are you gonna build this?
make sure you review the code using coderabbit