exports data of a data component to a PDF file
id | string|object|array | the exported view or its ID or an array of IDs |
options | object | optional, configuration options |
object | a "promise" object. The promise is resolved with the contents of a PDF file that is ready for downloading. |
webix.toPDF($$("table"),{
filename: "datatable",
// other config options
});
If the first parameter is the array of IDs, several views are exported.
webix.toPDF(["datatable","chart"]);
Configuration options can contain several useful settings. For example, canvas-based components like Chart can be exported as images, if you pass display:"image" parameter:
webix.toPDF("chart", { display:"image" });
The method returns all data specified in the columns parameter of a datatable view. The data is exported into a PDF document with the "data" name.
However, you may need to get some particular data or customize file properties.
Export API allows