vue安裝使用v-chart時報錯解決方案


npm i v-charts echarts -S

  1.在main.js中使用報以下錯

liquidFill echarts/lib/visual/dataColor 找不到

  出現此原因是因為版本問題

npm WARN echarts-liquidfill@2.0.6 requires a peer of echarts@^4.8.0 but none is installed. You must install peer dependencies yourself.
npm WARN echarts-liquidfill@2.0.6 requires a peer of zrender@^4.3.1 but none is installed. You must install peer dependencies yourself.

  解決方案

npm i echarts@^4.8.0 zrender@^4.3.1

  2.如果出現這樣的報錯

Component series.liquidFill not exists. Load it first.

  解決辦法

import 'echarts-liquidfill/src/liquidFill.js'

  


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM