|
@@ -1,14 +1,28 @@
|
|
import { createApp } from 'vue'
|
|
import { createApp } from 'vue'
|
|
import { createPinia } from 'pinia'
|
|
import { createPinia } from 'pinia'
|
|
-
|
|
|
|
import App from './App.vue'
|
|
import App from './App.vue'
|
|
import router from './router'
|
|
import router from './router'
|
|
-
|
|
|
|
-import './assets/main.css'
|
|
|
|
|
|
+// 样式
|
|
|
|
+import '@/assets/main.css'
|
|
|
|
+// 动画
|
|
|
|
+import 'animate.css'
|
|
|
|
+// element
|
|
|
|
+import ElementPlus from 'element-plus'
|
|
|
|
+import 'element-plus/dist/index.css'
|
|
|
|
+import locale from 'element-plus/lib/locale/lang/zh-cn'
|
|
|
|
+import * as ElementPlusIconsVue from '@element-plus/icons-vue'
|
|
|
|
+// moment
|
|
|
|
+import moment from 'moment'
|
|
|
|
|
|
const app = createApp(App)
|
|
const app = createApp(App)
|
|
-
|
|
|
|
app.use(createPinia())
|
|
app.use(createPinia())
|
|
app.use(router)
|
|
app.use(router)
|
|
|
|
+app.use(ElementPlus, { locale })
|
|
|
|
+for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
|
|
|
|
+ app.component(key, component)
|
|
|
|
+}
|
|
|
|
+app.config.globalProperties.$moment = moment
|
|
|
|
+
|
|
|
|
+app.config.globalProperties.$limit = parseInt(import.meta.env.VITE_APP_PAGE_SIZE) || 10
|
|
|
|
|
|
app.mount('#app')
|
|
app.mount('#app')
|