共1个回答
AD
游客AdtNgf
Highstock 是基于 Highcharts 创建的专门用于股票图及大数据了时间轴图表, 包含 Highcharts 所有功能。
通过Highcharts Vue
使用Highstock
方法:
import Vue from "vue";
import App from "./App.vue";
import Highcharts from "highcharts";
import Stock from "highcharts/modules/stock";
import HighchartsVue from "highcharts-vue";
import Indicators from "highcharts/indicators/indicators-all";
import DataModule from "highcharts/modules/data";
import DragPanes from "highcharts/modules/drag-panes";
import AnnotationsAdvanced from "highcharts/modules/annotations-advanced";
import PriceIndicator from "highcharts/modules/price-indicator";
import StockTools from "highcharts/modules/stock-tools";
DataModule(Highcharts);
DragPanes(Highcharts);
Stock(Highcharts);
Indicators(Highcharts);
PriceIndicator(Highcharts);
AnnotationsAdvanced(Highcharts);
StockTools(Highcharts);
Vue.use(HighchartsVue);
new Vue({
el: "#app",
render: (h) => h(App)
});
详细示例参见:https://codesandbox.io/s/highcharts-vue-demo-forked-pebej