Collaborative PDF editing for @pdfrx/react. It provides a ready-made React
viewer plus the browser client, operation protocols, page-source adapter, and
mixed-source export tools needed to synchronize page, annotation, and form
changes through an application-hosted relay.
npm package · Local example · API reference · Detailed guide
@pdfrx/react toolbar,
responsive layout, editing tools, and export UI.npm install @pdfrx/colab @pdfrx/react react react-dom
import { CollaborativePdfViewer } from '@pdfrx/colab';
import '@pdfrx/react/styles.css';
import '@pdfrx/colab/styles.css';
export function ReviewRoom() {
return (
<CollaborativePdfViewer
actorId="user-42"
relayUrl="wss://relay.example.com/collaboration"
sessionId="review-123"
src="/documents/review.pdf"
wasmModulesUrl="/pdfium/"
className="review-room"
/>
);
}
.review-room {
height: 100dvh;
min-height: 0;
}
relayUrl must be an application-hosted WebSocket service implementing the
exported collaboration protocol. This package does not include or operate a
hosted production service. The relay must sequence revision-checked page,
annotation, and form operations and expose immutable PDF/raster source
PUT/GET endpoints.
Run npm run dev:colab in this repository to start the example application and
reference relay for local development.
CollaborativePdfViewerProps
documents all component inputs.@pdfrx/engine ·
@pdfrx/viewer ·
@pdfrx/reactMIT
Collaborative React viewer, strict-revision session protocols, browser relay client, virtual-page adapter, and mixed-source PDF export composition for the pdfrx package family.
The package keeps rendering and PDF mutation client-local. A relay sequences semantic page, annotation, and form operations; each participant applies the resulting authoritative state to its own open
PdfDocumentinstances.