PDF Export uses Value Getters and Value Formatters but does not export Cell Renderer output. Export callbacks can replace the resulting text without changing the grid.
Document Title Copy Link
Use documentTitle to set the PDF metadata title and render a visible title above the table. Use documentTitleStyle to configure its font, colour, border, padding, margin, alignment, wrapping, line height, line limit, and overflow behaviour.
Customising Exported Values Copy Link
api.exportDataAsPdf({
processCellCallback: (params) => params.formatValue(params.value),
processHeaderCallback: (params) => params.column.getColDef().headerName ?? params.column.getColId(),
processGroupHeaderCallback: (params) => params.columnGroup.getColGroupDef()?.headerName ?? '',
processRowGroupCallback: (params) => `Group: ${params.node.key ?? ''}`,
});processCellCallbackcustomises body cell text.processHeaderCallbackcustomises column header text.processGroupHeaderCallbackcustomises column-group header text.processRowGroupCallbackcustomises row-group text. Group indentation is applied independently.
These callbacks return text. To style the processed result, use processStyleCallback; its value is the final exported string.
Additional Content Copy Link
Use prependContent, appendContent, or getCustomContentBelowRow to add content that is not displayed in the grid. Strings create full-width rows. Use PdfCell[][] for explicit spans and styling.
See PDF Export - Master Detail for an example that uses getCustomContentBelowRow to include detail data below each master row.