realchart-export
v1.1.3
Published
Wooritech realchart exporting moudle
Downloads
180
Readme
realchart-export
This is just a realchart-export module copied from realchart v1.0.1 This package is generated for simplicity of use.
Installation
The package expects that global realchart variable is set. It also doesn't export anything.
npm install realchart-export
import { RealchartExport } from "realchart-export";
import "realchart-export/dist/realchart-export.css";
Or include the script in your HTML file.
<link href="./styles/realchart-export.css" rel="stylesheet">
<script src = "./lib/realchart-export/index.js">
Basic Use
const config = {
export: {
useLibrary: true,
menus: ['png', 'jpeg', 'svg'],
hideScrollbar: true,
hideNavigator: true,
hideZoomButton: true,
...
}
};
const chart = Realchart.createChart(document, id, config);
chart.export({
type: 'png',
fileName: 'realchart'
});
import { createChart } from "realchart";
import { RealchartExport } from "realchart-export";
import "realchart/dist/realchart-style.css";
import "realchart-export/dist/realchart-export.css";
const chart = createChart(document, id, config);
RealchartExport(chart);
chart.export({
type: 'png',
fileName: 'realchart'
});