Loading...
A Hook for exporting canvas content as an image.
const { exportPNG, exportJPEG, exportSVG } = useExport();
const {exportPNG: (fileName, options) => void,exportJPEG: (fileName, options) => void,exportSVG: (fileName, options) => void} = useExport();
Parameter | Description | Type | Default Value |
---|---|---|---|
exportPNG | Export as PNG | (fileName:string, options: Export.ToImageOptions = {}) => void | ('chart', {}) => void |
exportJPEG | Export as JPEG | (fileName:string, options: Export.ToImageOptions = {}) => void | ('chart', {}) => void |
exportSVG | Export as SVG | (fileName:string, options: Export.ToSVGOptions = {}) => void | ('chart', {}) => void |
None