From 23657547ab28fa65c2369ded8e73929dee76c750 Mon Sep 17 00:00:00 2001 From: vben Date: Tue, 9 Feb 2021 23:06:00 +0800 Subject: [PATCH] perf: remove unless code --- package.json | 3 +- src/components/Application/index.ts | 3 - .../Application/src/AppLocalePicker.vue | 13 ++-- src/components/Application/src/AppLogo.vue | 4 +- .../Application/src/AppProvider.vue | 7 +-- .../Application/src/search/AppSearch.vue | 49 ++++++++------- .../src/search/AppSearchFooter.vue | 3 +- .../Application/src/search/AppSearchModal.vue | 21 ++++--- .../Application/src/search/useMenuSearch.ts | 10 +++- src/components/Authority/index.ts | 4 -- src/components/Basic/src/BasicArrow.vue | 4 +- src/components/Basic/src/BasicHelp.vue | 60 +++++++++---------- src/components/Basic/src/BasicTitle.vue | 5 +- src/components/Button/index.ts | 2 - src/components/Button/src/BasicButton.vue | 1 + .../Button/src/PopConfirmButton.vue | 5 +- src/components/ClickOutSide/index.ts | 4 -- src/components/Container/index.ts | 2 - src/components/Drawer/index.ts | 4 -- src/components/Dropdown/index.ts | 3 - src/components/Form/index.ts | 3 - src/components/Icon/index.ts | 3 - src/components/Modal/index.ts | 3 - src/components/Scrollbar/index.ts | 3 - src/components/util.tsx | 9 --- src/design/ant/btn.less | 2 +- src/design/ant/index.less | 26 -------- src/directives/ripple/index.ts | 2 +- src/settings/designSetting.ts | 2 +- src/utils/env.ts | 15 +++-- src/utils/uuid.ts | 1 + 31 files changed, 107 insertions(+), 169 deletions(-) diff --git a/package.json b/package.json index 5d321cb3..4d0d755b 100644 --- a/package.json +++ b/package.json @@ -14,7 +14,8 @@ "clean:cache": "rimraf node_modules/.cache/ && rimraf node_modules/.vite", "clean:lib": "npx rimraf node_modules", "typecheck": "vuedx-typecheck .", - "lint:eslint": "eslint \"{src,mock}/**/*.{vue,ts,tsx}\" --fix", + "lint:eslint": "eslint \"{src,mock}/**/*.{vue,ts,tsx}\" ", + "lint:eslint:fix": "eslint \"{src,mock}/**/*.{vue,ts,tsx}\" --fix", "lint:prettier": "prettier --write --loglevel warn \"src/**/*.{js,json,tsx,css,less,scss,vue,html,md}\"", "lint:stylelint": "stylelint --fix \"**/*.{vue,less,postcss,css,scss}\" --cache --cache-location node_modules/.cache/stylelint/", "lint:ls-lint": "ls-lint", diff --git a/src/components/Application/index.ts b/src/components/Application/index.ts index 1dfffc12..98f79e26 100644 --- a/src/components/Application/index.ts +++ b/src/components/Application/index.ts @@ -1,7 +1,6 @@ import { createAsyncComponent } from '/@/utils/factory/createAsyncComponent'; import AppLogo from './src/AppLogo.vue'; import AppProvider from './src/AppProvider.vue'; -import { withInstall } from '../util'; export const AppLocalePicker = createAsyncComponent(() => import('./src/AppLocalePicker.vue')); export const AppSearch = createAsyncComponent(() => import('./src/search/AppSearch.vue'), { @@ -10,5 +9,3 @@ export const AppSearch = createAsyncComponent(() => import('./src/search/AppSear export { useAppProviderContext } from './src/useAppContext'; export { AppLogo, AppProvider }; - -withInstall(AppLogo, AppProvider); diff --git a/src/components/Application/src/AppLocalePicker.vue b/src/components/Application/src/AppLocalePicker.vue index 48204d86..fa111c0f 100644 --- a/src/components/Application/src/AppLocalePicker.vue +++ b/src/components/Application/src/AppLocalePicker.vue @@ -17,19 +17,18 @@ diff --git a/src/components/Application/src/search/AppSearch.vue b/src/components/Application/src/search/AppSearch.vue index 3d6faa73..ffe030f1 100644 --- a/src/components/Application/src/search/AppSearch.vue +++ b/src/components/Application/src/search/AppSearch.vue @@ -1,23 +1,11 @@ - -