久久r热视频,国产午夜精品一区二区三区视频,亚洲精品自拍偷拍,欧美日韩精品二区

您的位置:首頁技術(shù)文章
文章詳情頁

Vue項目如何引入bootstrap、elementUI、echarts

瀏覽:138日期:2022-10-23 14:36:27

引入bootstrap

安裝依賴包

cnpm install bootstrap --save-devcnpm install jquery --save-devcnpm install popper.js --save-dev

全局引入

在項目中根目錄下的main.js中添加如下代碼:

import ’bootstrap’import $ from ’jquery’

在vue文件中引用

<script>import ’bootstrap/dist/css/bootstrap.min.css’import ’bootstrap/dist/js/bootstrap.min.js’</script>

引入elementUI

安裝 elementUI

打開終端,輸入以下內(nèi)容

npm i element-ui -S

全局引入

在項目中根目錄下的main.js中添加如下代碼:

import ElementUI from ’element-ui’import ’element-ui/lib/theme-chalk/index.css’;Vue.use(ElementUI)

引入echarts

安裝echarts

npm install echarts -S

2.全局引入main.js

// 引入echartsimport echarts from ’echarts’Vue.prototype.$echarts = echarts

以上就是本文的全部內(nèi)容,希望對大家的學(xué)習(xí)有所幫助,也希望大家多多支持好吧啦網(wǎng)。

標(biāo)簽: Vue
相關(guān)文章:
主站蜘蛛池模板: 务川| 山丹县| 航空| 关岭| 迭部县| 涿州市| 临江市| 文安县| 墨竹工卡县| 荥阳市| 铁力市| 南华县| 吐鲁番市| 驻马店市| 沁阳市| 玛沁县| 饶河县| 夏邑县| 兴隆县| 丹东市| 济宁市| 商洛市| 霸州市| 景宁| 东海县| 宁国市| 新泰市| 常山县| 平湖市| 扎兰屯市| 宿州市| 文安县| 赫章县| 岳阳县| 永丰县| 景宁| 建湖县| 仁怀市| 巴彦县| 仲巴县| 肥东县|