Pagination - quick start
The aim of this article is to get you up and running with CKEditor 5 pagination.
Follow the steps below:
- Subscribe to Pagination. This feature is available in the Flexible plan. Contact us for a tailored offer.
- Generate your access credentials in the CKEditor Ecosystem customer dashboard.
- Configure CKEditor.
All the steps are explained in details below.
You can also sign up for the CKEditor Premium Features 30-day free trial if you want to test this feature first.
Please refer to the Premium Features trial guide for more details.
# Subscribe to CKEditor Cloud Services
Create an account in CKEditor Cloud Services by signing up to Pagination. After signing up, you will receive access to the customer dashboard (CKEditor Ecosystem dashboard).
# Log in to the CKEditor Ecosystem dashboard
Log in to the CKEditor Ecosystem dashboard. You will receive a confirmation email and will be asked to create a password for your account. Keep it safe. Navigate to “Your products > CKEditor”.
From the list of available subscriptions in the dashboard choose the Pagination subscription and press the “Manage” link.
On the next page you will see the subscription parameters overview together with the management area.
# Generate the license key
Once you enter the management console for pagination, you have access to the license key needed to run the feature.
# Integrating the pagination feature with CKEditor 5
To install the plugin into your WYSIWYG editor, use the online builder to generate a custom CKEditor 5 build with the plugin enabled. Alternatively, refer to the installation guide in the plugin documentation to do it on your own.
To set up the feature, you need to add the license key in your CKEditor 5 configuration as described in the installation guide.
# Example configuration
{
pagination: {
// A4
pageWidth: '21cm',
pageHeight: '29.7cm',
pageMargins: {
top: '20mm',
bottom: '20mm',
left: '12mm',
right: '12mm'
}
},
licenseKey: 'ePxU5bvVnL3klbnhQ983ernPNIrni8AOYcxKVWvxU1TJUmk='
}
Apart from setting the license key, the configuration of this feature in the editor is the key to allow pagination to measure where the page breaks would be and to produce a 1:1 result with the export to PDF or Word features. Refer to the configuration section of the Pagination feature guide for more information.