Render PDFs in SuperDoc. PDF is a separate document type with its own rendering pipeline (pdf.js), distinct from the DOCX editor surface.Documentation Index
Fetch the complete documentation index at: https://docs.superdoc.dev/llms.txt
Use this file to discover all available pages before exploring further.
PDF rendering is configured through
modules.pdf today, but it isn’t a built-in UI surface: it’s a viewer for a different file type.Install pdf.js
Installpdfjs-dist in your app:
>= 5.4.296.
Quick start
Worker setup (recommended)
This is the recommended approach because the worker is configured once for the whole application.Configuration
Preloaded pdf.js library instance
PDF.js worker source URL (falls back to CDN when omitted)
Whether to auto-configure pdf.js worker
Enable text layer rendering (for text selection)
Canvas render scale (quality)
Events
pdf:document-ready
Fired when all PDF pages are rendered.
Notes
outputScaleaffects render quality; zooming does not re-render the canvas.- If you need text selection, enable
textLayer: true.

