import { createApp } from "vue"; import "./style.css"; import App from "./App.vue"; // 引入路由 import router from "./router"; import ElementPlus from "element-plus"; import "element-plus/dist/index.css"; import "./assets/css/common.css"; import zhCn from "element-plus/dist/locale/zh-cn.mjs"; import { createPinia } from "pinia"; //下面两行为持久化 import piniaPluginPersistedstate from 'pinia-plugin-persistedstate' const app = createApp(App) const pinia = createPinia(); pinia.use(piniaPluginPersistedstate); // 引入 vConsole // import VConsole from "vconsole"; // 初始化 vConsole // const vConsole = new VConsole(); app.use(pinia) app.use(router) app .use(ElementPlus, { locale: zhCn, }) app.mount("#app");