Quickstart

Before installing Univer PDFs, learn the four concepts that shape every PDF integration:

  • Plugin
  • Snapshot and data model
  • Command
  • Facade API

Basic Concepts

Plugins

Univer PDFs is assembled from plugins. UniverPdfsPlugin registers the UNIVER_PDF unit model and durable PDF commands. UniverPdfsUIPlugin adds the browser viewer and, by default, editing controls. Add print, exchange, or collaboration packages only when your application needs those capabilities.

These plugins run on the shared Univer core, rendering, design, and UI services. They are technical dependencies of the PDF application; no prior experience with another Univer product is required.

Snapshot and data model

One PDF unit is persisted as an IPdfUnitData snapshot. Its document is the imported or blank source baseline, while accepted edits are persisted in editState rather than rewriting that baseline in place.

Use pdf.save() to obtain the complete current snapshot. pdf.getDocument() returns the source baseline, so use save() when persisting user edits.

Command

Runtime changes are executed through commands. Commands keep validation, view updates, edit history, and export intent in the same change pipeline. PDF Facade methods prepare command parameters and execute those commands for you.

Caution

Do not mutate a running PDF unit's snapshot or source document directly. Use PDF Facade methods or registered commands.

Facade API

Import @univerjs-pro/pdfs/facade after the core Facade entry to add PDF APIs to FUniver. The entry provides methods such as createPdf(), getActivePdf(), and getPdf().

See Using the PDF Facade API for the complete setup and examples.

Next, continue to Installation & Basic Usage.

How is this guide?

© 2026 DreamNum Co., Ltd.