首先在vue項(xiàng)目中安裝echarts組件,你可以使用如下命令通過(guò) npm 安裝 ECharts
npm install echarts --save
引入組件,通過(guò) npm 上安裝的 ECharts 和 zrender 會(huì)放在node_modules目錄下??梢灾苯釉陧?xiàng)目代碼中 require('echarts') 得到 ECharts。
首先在vue項(xiàng)目中安裝echarts組件,你可以使用如下命令通過(guò) npm 安裝 ECharts
npm install echarts --save
引入組件,通過(guò) npm 上安裝的 ECharts 和 zrender 會(huì)放在node_modules目錄下??梢灾苯釉陧?xiàng)目代碼中 require('echarts') 得到 ECharts。