toCSV of common helpers, Methods Webix Docs
objectoptional, a set of configuration options that define what data will be displayed in the CSV file
| promise | a "promise" object. The promise is resolved with the contents of a CSV file that is ready for downloading. |
Example
webix.toCSV($$("table"), {
filename: "table",
// other config options
});
Related samples
Details
The method returns all data specified in the dataset of a component, or in the columns parameter of the DataTable view. The data are exported into a CSV document with the "Data" name by default.
However, you may need to get some particular data, or customize the file name.
Export API allows
- providing a custom filename
- stripping HTML tags from the cells
- setting custom columns for export
- defining custom header or template for data in the specified column
- including extra fields into export
- rendering a template set in the widget dataset
- setting the desired columns' delimiter
- disabling file download in a browser, if necessary
- ignoring particular columns during export
- omitting the header or footer of Datatable during export
- outputting certain data from the data set of Datatable
See also