Vue3+Vite+ElementPlus構(gòu)建學(xué)習(xí)筆記

1、Node.js 查看
node -v
2、如果你的網(wǎng)絡(luò)環(huán)境不佳,推薦使用 換源
npm config set registry https://registry.npmmirror.com
3、Vue 3 編碼規(guī)范 使用
1.編碼語言:TypeScript
2.代碼風(fēng)格:組合式API
3.簡寫形式:setup語法糖
4、所需網(wǎng)址
https://cn.vuejs.org/guide/quick-start
5、 構(gòu)建 指令
vue
npm create vue@latest


vite
npm create vite@latest

6、 在 Vue 3 加入 Element Plus 庫
安裝
npm install element-plus --save
完整引入
// main.ts
import { createApp } from 'vue'
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import App from './App.vue'
const app = createApp(App)
app.use(ElementPlus)
app.mount('#app')// tsconfig.json
{
"compilerOptions": {
// ...
"types": ["element-plus/global"]
}
}

總結(jié)
到此這篇關(guān)于Vue3+Vite+ElementPlus構(gòu)建的文章就介紹到這了,更多相關(guān)Vue3+Vite+ElementPlus構(gòu)建內(nèi)容請搜索腳本之家以前的文章或繼續(xù)瀏覽下面的相關(guān)文章希望大家以后多多支持腳本之家!
相關(guān)文章
基于vue實現(xiàn)圖片預(yù)覽功能并顯示在彈窗的最上方
這篇文章主要為大家詳細介紹了如何基于vue實現(xiàn)圖片預(yù)覽功能并顯示在彈窗的最上方,感興趣的小伙伴可以跟隨小編一起學(xué)習(xí)一下2024-10-10
Ant?Design_Form表單上傳文件組件實現(xiàn)詳解
這篇文章主要為大家介紹了Ant?Design_Form表單上傳文件組件實現(xiàn)詳解,有需要的朋友可以借鑒參考下,希望能夠有所幫助,祝大家多多進步,早日升職加薪2023-03-03
vue關(guān)于重置表單數(shù)據(jù)出現(xiàn)undefined的解決
這篇文章主要介紹了vue關(guān)于重置表單數(shù)據(jù)出現(xiàn)undefined的解決方案,具有很好的參考價值,希望對大家有所幫助。如有錯誤或未考慮完全的地方,望不吝賜教2022-09-09
vue2.0中g(shù)oods選購欄滾動算法的實現(xiàn)代碼
這篇文章主要介紹了vue2.0中g(shù)oods選購欄滾動算法的實現(xiàn)代碼,需要的朋友可以參考下2017-05-05

