Use the template manager for all template related interactions with the API
With JavaScript you can create a function for applying a template. All you need is a template file, insert by the user, and the grid cell
where the template should to be applied. Downloading a template file is possible from the save template dialog in trueChart.
example
JavaScript implementation for applying a template
const applyTemplate = async (templateFile, cell) => {
const dataMap = await trueChartInstance.TemplateManager.generateDataMap(template);
// if you like to edit the data mapping, here is the place to go
return trueChartInstance.TemplateManager.applyTemplate(template)
}
Use the template manager for all template related interactions with the API
With JavaScript you can create a function for applying a template. All you need is a template file, insert by the user, and the grid cell where the template should to be applied. Downloading a template file is possible from the save template dialog in trueChart.
JavaScript implementation for applying a template
const applyTemplate = async (templateFile, cell) => { const dataMap = await trueChartInstance.TemplateManager.generateDataMap(template); // if you like to edit the data mapping, here is the place to go return trueChartInstance.TemplateManager.applyTemplate(template) }