Columns
When using the saveExcel
method we can pass to it options for the customization of the columns that will be exported to Excel.
You can specify the following column options:
Hidden State
To hide a particular column from the exported file, use the hidden
column configuration.
Locked State
When exporting to Excel, we can lock columns by defining the locked
property for the selected columns. As a result, you can display specific columns at all times while the user scrolls the Excel file.
Templates
The Excel Export functionality supports templates that you can use for customizing the group and footer elements.
The templates must return text content. HTML elements cannot be converted to Excel column values.
Group Header Template
You can use the group header template to customize the header rows of the groups. To use a custom template set the groupHeader
property of selected column to a Function or a Vue Component.
Group Footer Template
You can use the group footer template to customize the footer rows of the groups. To use a custom template set the groupFooter
property of a column to a Function or a Vue Component.
Footer Template
You can use the footer template to customize the column footer. To use a custom template set the footer
property of selected column to a Function or a Vue Component .
Multi-Column Headers
The saveExcel
method supports multi-column headers by using column groups.