From 9fd5b8a472a3dabf668f021829d5b71875d1057f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B1=89=E5=B9=BF?= Date: Wed, 21 Sep 2022 20:32:56 +0800 Subject: [PATCH] typo[main]follow ts-lint --- src/main.ts | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/src/main.ts b/src/main.ts index a06240b..4efdca9 100644 --- a/src/main.ts +++ b/src/main.ts @@ -1,4 +1,4 @@ -import {createApp} from 'vue' +import { createApp } from 'vue' import { createPinia } from 'pinia' import ElementPlus from 'element-plus' import * as ElementPlusIconsVue from '@element-plus/icons-vue' @@ -9,26 +9,25 @@ import { usePermissStore } from './store/permiss' import 'element-plus/dist/index.css' import './assets/css/icon.css' - const app = createApp(App) app.use(createPinia()) app.use(router) app.use(ElementPlus, { - locale: zhCn, + locale: zhCn, }) // 注册elementplus图标 for (const [key, component] of Object.entries(ElementPlusIconsVue)) { - app.component(key, component) + app.component(key, component) } // 自定义权限指令 const permiss = usePermissStore() app.directive('permiss', { - mounted(el, binding) { - if(!permiss.key.includes(String(binding.value))){ - el['hidden'] = true; - } + mounted(el, binding) { + if (!permiss.key.includes(String(binding.value))) { + el['hidden'] = true } + }, }) -app.mount('#app') \ No newline at end of file +app.mount('#app')