Skip to main content
Modules are opt-in features configured through the SuperDoc modules option. Enable only what you need.
const superdoc = new SuperDoc({
  selector: '#editor',
  document: 'contract.docx',
  modules: {
    toolbar: { selector: '#toolbar' },
    comments: { allowResolve: true },
    collaboration: { ydoc, provider },
    contextMenu: { includeDefaultItems: true },
    links: { popoverResolver: (ctx) => ({ type: 'default' }) }
  }
});

Available modules

Collaboration

Real-time multi-user editing with Yjs

Comments

Threaded discussions and annotations

Toolbar

Customizable formatting controls

Links

Customize the link click popover or bring your own UI

Context Menu

Right-click actions and custom commands

PDF

PDF viewer setup and configuration

Whiteboard

Annotation layer for documents
Each module is configured via modules.<name> in the SuperDoc configuration. See individual module pages for all available options. These features are configured at the top level rather than through modules, but are commonly used alongside modules.

Track Changes

Accept/reject workflow with documentMode: 'suggesting'

AI Agents

Headless mode for server-side document processing and LLM workflows