@nebuladocs/engine
v0.2.0
Published
PDF.js rendering and pdf-lib export engine for the PDF SDK
Readme
@nebuladocs/engine
PDF.js rendering (load, render, search, thumbnails, page import) and pdf-lib
export for the NebulaDocs SDK. Depends on @nebuladocs/core; no framework
dependency.
PDF.js worker
The worker ships inside this package. Resolve it with the exported helper and
pass it to the editor as workerSrc:
import { pdfWorkerUrl } from "@nebuladocs/engine";
// <PdfEditor workerSrc={pdfWorkerUrl()} … /> (React)
// [workerSrc]="workerSrc" (Angular)pdfWorkerUrl() resolves @nebuladocs/engine/dist/pdf.worker.min.mjs relative to
the installed package (works with Vite, webpack 5, esbuild and Angular's builder).
You may also reference the file directly via the ./pdf.worker.min.mjs subpath
export. The SDK never falls back to PDF.js' fake worker.
Proprietary — see LICENSE.
