提交 e5b2cc1e 作者: Vben

chore: update deps

上级 7b4fcd2e
...@@ -6,6 +6,3 @@ VITE_GLOB_APP_TITLE = Vben Admin ...@@ -6,6 +6,3 @@ VITE_GLOB_APP_TITLE = Vben Admin
# spa shortname # spa shortname
VITE_GLOB_APP_SHORT_NAME = vue_vben_admin VITE_GLOB_APP_SHORT_NAME = vue_vben_admin
VITE_DYNAMIC_IMPORT = false
...@@ -30,7 +30,6 @@ export interface ViteEnv { ...@@ -30,7 +30,6 @@ export interface ViteEnv {
VITE_BUILD_COMPRESS: 'gzip' | 'brotli' | 'none'; VITE_BUILD_COMPRESS: 'gzip' | 'brotli' | 'none';
VITE_LEGACY: boolean; VITE_LEGACY: boolean;
VITE_USE_IMAGEMIN: boolean; VITE_USE_IMAGEMIN: boolean;
VITE_DYNAMIC_IMPORT: boolean;
} }
// Read all environment variable configuration files to process.env // Read all environment variable configuration files to process.env
......
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
"devDependencies": { "devDependencies": {
"@commitlint/cli": "^12.0.1", "@commitlint/cli": "^12.0.1",
"@commitlint/config-conventional": "^12.0.1", "@commitlint/config-conventional": "^12.0.1",
"@iconify/json": "^1.1.308", "@iconify/json": "^1.1.310",
"@ls-lint/ls-lint": "^1.9.2", "@ls-lint/ls-lint": "^1.9.2",
"@purge-icons/generated": "^0.7.0", "@purge-icons/generated": "^0.7.0",
"@types/crypto-js": "^4.0.1", "@types/crypto-js": "^4.0.1",
...@@ -68,8 +68,8 @@ ...@@ -68,8 +68,8 @@
"@types/rollup-plugin-visualizer": "^2.6.0", "@types/rollup-plugin-visualizer": "^2.6.0",
"@types/sortablejs": "^1.10.6", "@types/sortablejs": "^1.10.6",
"@types/yargs": "^16.0.0", "@types/yargs": "^16.0.0",
"@typescript-eslint/eslint-plugin": "^4.15.2", "@typescript-eslint/eslint-plugin": "^4.16.1",
"@typescript-eslint/parser": "^4.15.2", "@typescript-eslint/parser": "^4.16.1",
"@vitejs/plugin-legacy": "^1.3.1", "@vitejs/plugin-legacy": "^1.3.1",
"@vitejs/plugin-vue": "^1.1.5", "@vitejs/plugin-vue": "^1.1.5",
"@vitejs/plugin-vue-jsx": "^1.1.2", "@vitejs/plugin-vue-jsx": "^1.1.2",
...@@ -100,15 +100,15 @@ ...@@ -100,15 +100,15 @@
"stylelint-config-standard": "^20.0.0", "stylelint-config-standard": "^20.0.0",
"stylelint-order": "^4.1.0", "stylelint-order": "^4.1.0",
"ts-node": "^9.1.1", "ts-node": "^9.1.1",
"typescript": "4.1.5", "typescript": "4.2.2",
"vite": "^2.0.4", "vite": "^2.0.4",
"vite-plugin-compression": "^0.2.2", "vite-plugin-compression": "^0.2.3",
"vite-plugin-html": "^2.0.2", "vite-plugin-html": "^2.0.3",
"vite-plugin-imagemin": "^0.2.8", "vite-plugin-imagemin": "^0.2.9",
"vite-plugin-mock": "^2.1.5", "vite-plugin-mock": "^2.1.5",
"vite-plugin-purge-icons": "^0.7.0", "vite-plugin-purge-icons": "^0.7.0",
"vite-plugin-pwa": "^0.5.6", "vite-plugin-pwa": "^0.5.6",
"vite-plugin-style-import": "^0.7.5", "vite-plugin-style-import": "^0.7.6",
"vite-plugin-theme": "^0.4.8", "vite-plugin-theme": "^0.4.8",
"vite-plugin-windicss": "0.6.2", "vite-plugin-windicss": "0.6.2",
"vue-eslint-parser": "^7.5.0", "vue-eslint-parser": "^7.5.0",
......
...@@ -9,7 +9,6 @@ ...@@ -9,7 +9,6 @@
</template> </template>
<script lang="ts"> <script lang="ts">
import { defineComponent, computed } from 'vue'; import { defineComponent, computed } from 'vue';
import { RightOutlined } from '@ant-design/icons-vue';
import { useDesign } from '/@/hooks/web/useDesign'; import { useDesign } from '/@/hooks/web/useDesign';
...@@ -19,7 +18,7 @@ ...@@ -19,7 +18,7 @@
export default defineComponent({ export default defineComponent({
name: 'BasicArrow', name: 'BasicArrow',
components: { RightOutlined, Icon }, components: { Icon },
props: { props: {
// Expand contract, expand by default // Expand contract, expand by default
expand: propTypes.bool, expand: propTypes.bool,
......
...@@ -18,12 +18,7 @@ let dynamicViewsModules: Record< ...@@ -18,12 +18,7 @@ let dynamicViewsModules: Record<
// 动态引入 // 动态引入
function asyncImportRoute(routes: AppRouteRecordRaw[] | undefined) { function asyncImportRoute(routes: AppRouteRecordRaw[] | undefined) {
// TODO It may be a bug in Vite. When the conditions are not established, the dynamically imported files will still be packaged in. dynamicViewsModules = dynamicViewsModules || import.meta.glob('../../views/**/*.{vue,tsx}');
if (!__DYNAMIC_IMPORT__) {
dynamicViewsModules = {};
} else {
dynamicViewsModules = dynamicViewsModules || import.meta.glob('../../views/**/*.{vue,tsx}');
}
if (!routes) return; if (!routes) return;
routes.forEach((item) => { routes.forEach((item) => {
......
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
</template> </template>
<script lang="ts"> <script lang="ts">
import { defineComponent, reactive, watchEffect, computed, toRefs } from 'vue'; import { defineComponent, reactive, watchEffect, computed, toRefs } from 'vue';
import { Alert, Tag, Input } from 'ant-design-vue'; import { Tag, Input } from 'ant-design-vue';
import { PageWrapper } from '/@/components/Page'; import { PageWrapper } from '/@/components/Page';
...@@ -66,7 +66,6 @@ ...@@ -66,7 +66,6 @@
PageWrapper, PageWrapper,
[Input.name]: Input, [Input.name]: Input,
InputTextArea: Input.TextArea, InputTextArea: Input.TextArea,
Alert,
Tag, Tag,
}, },
setup() { setup() {
......
# Websocket Server
Simple background for testing ws interface
## Usage
```js
cd ./test/websocket-server
yarn install
yarn start
```
import type { App } from 'vue'; import type { App } from 'vue';
declare global { declare global {
declare const __DYNAMIC_IMPORT__: boolean;
declare interface Window { declare interface Window {
// Global vue app instance // Global vue app instance
__APP__: App<Element>; __APP__: App<Element>;
......
...@@ -21,14 +21,7 @@ export default ({ command, mode }: ConfigEnv): UserConfig => { ...@@ -21,14 +21,7 @@ export default ({ command, mode }: ConfigEnv): UserConfig => {
// The boolean type read by loadEnv is a string. This function can be converted to boolean type // The boolean type read by loadEnv is a string. This function can be converted to boolean type
const viteEnv = wrapperEnv(env); const viteEnv = wrapperEnv(env);
const { const { VITE_PORT, VITE_PUBLIC_PATH, VITE_PROXY, VITE_DROP_CONSOLE, VITE_LEGACY } = viteEnv;
VITE_PORT,
VITE_PUBLIC_PATH,
VITE_PROXY,
VITE_DROP_CONSOLE,
VITE_LEGACY,
VITE_DYNAMIC_IMPORT,
} = viteEnv;
const isBuild = command === 'build'; const isBuild = command === 'build';
...@@ -75,7 +68,6 @@ export default ({ command, mode }: ConfigEnv): UserConfig => { ...@@ -75,7 +68,6 @@ export default ({ command, mode }: ConfigEnv): UserConfig => {
define: { define: {
// setting vue-i18-next // setting vue-i18-next
// Suppress warning // Suppress warning
__DYNAMIC_IMPORT__: VITE_DYNAMIC_IMPORT,
__VUE_I18N_LEGACY_API__: false, __VUE_I18N_LEGACY_API__: false,
__VUE_I18N_FULL_INSTALL__: false, __VUE_I18N_FULL_INSTALL__: false,
__INTLIFY_PROD_DEVTOOLS__: false, __INTLIFY_PROD_DEVTOOLS__: false,
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论