Install | Tiptap Pagination
Installation
Section titled “Installation”This package supports both Tiptap v2 and v3. Choose the installation command based on your Tiptap version:
For Tiptap v3
Section titled “For Tiptap v3”# Install latest version (supports Tiptap v3)npm install tiptap-pagination-plus@latest
# Or explicitly install the tiptap-v3 tagnpm install tiptap-pagination-plus@tiptap-v3For Tiptap v2
Section titled “For Tiptap v2”# Install the tiptap-v2 tagnpm install tiptap-pagination-plus@tiptap-v2For Table with pagination
Section titled “For Table with pagination”If you need table pagination support, install the table plus package based on your Tiptap version:
For Tiptap v3
Section titled “For Tiptap v3”# Install latest version (supports Tiptap v3)npm install tiptap-table-plus@latest
# Or explicitly install the tiptap-v3 tagnpm install tiptap-table-plus@tiptap-v3Peer Dependencies for Tiptap v3:
npm install @tiptap/extension-table @tiptap/pmFor Tiptap v2
Section titled “For Tiptap v2”# Install the tiptap-v2 tagnpm install tiptap-table-plus@tiptap-v2Peer Dependencies for Tiptap v2:
npm install @tiptap/extension-table @tiptap/extension-table-cell @tiptap/extension-table-header @tiptap/extension-table-row @tiptap/pmNote: Make sure you have the appropriate peer dependencies installed for your Tiptap version as they are required for the package to function properly. The package will not work without these Tiptap extensions and ProseMirror.
Configuration Options
Section titled “Configuration Options”| Option | Type | Default | Description |
|---|---|---|---|
| pageHeight | number | 800 | Height of each page in pixels |
| pageWidth | number | 789 | Width of each page in pixels |
| pageGap | number | 50 | Gap between pages in pixels |
| pageGapBorderSize | number | 1 | Border size for page gaps |
| pageGapBorderColor | string | ”#e5e5e5” | Border color for page gaps |
| pageBreakBackground | string | ”#ffffff” | Background color for page gaps |
| pageHeaderHeight | number | 30 | Height of page header in pixels |
| pageFooterHeight | number | 30 | Height of page footer in pixels |
| footerRight | string | "{page}" | Custom HTML content to display in the footer right side (supports multiline and rich text) |
| footerLeft | string | "" | Custom HTML content to display in the footer left side (supports multiline and rich text) |
| headerRight | string | "" | Custom HTML content to display in the header right side (supports multiline and rich text) |
| headerLeft | string | "" | Custom HTML content to display in the header left side (supports multiline and rich text) |
| marginTop | number | 20 | Top margin for pages |
| marginBottom | number | 20 | Bottom margin for pages |
| marginLeft | number | 50 | Left margin for pages |
| marginRight | number | 50 | Right margin for pages |
| contentMarginTop | number | 10 | Top margin for content within pages |
| contentMarginBottom | number | 10 | Bottom margin for content within pages |
Note:
tiptap-pagination-plusextends the default Tiptap pagination extension with additional functionality.
tiptapplus.com is not an official Tiptap website and has no business affiliation with Tiptap.