From 90b588028a35b3670975c42c7640dfa6afb3f379 Mon Sep 17 00:00:00 2001 From: Hooray Hu <304327508@qq.com> Date: Wed, 26 Jun 2024 10:45:45 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=A2=9E=E5=8A=A0=E7=A6=81=E7=94=A8?= =?UTF-8?q?=E5=BC=80=E5=8F=91=E8=80=85=E5=B7=A5=E5=85=B7=E7=8E=AF=E5=A2=83?= =?UTF-8?q?=E5=8F=98=E9=87=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 2 ++ .env.production | 2 ++ .env.test | 2 ++ package.json | 1 + pnpm-lock.yaml | 20 +++++++++++--------- src/App.vue | 2 ++ 6 files changed, 20 insertions(+), 9 deletions(-) diff --git a/.env.development b/.env.development index 0b825f2..e7167d6 100755 --- a/.env.development +++ b/.env.development @@ -6,6 +6,8 @@ VITE_APP_TITLE = Fantastic-admin 基础版 VITE_APP_API_BASEURL = / # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空 VITE_APP_DEBUG_TOOL = +# 是否禁用开发者工具,可防止被调试 +VITE_APP_DISABLE_DEVTOOL = false # 是否开启代理 VITE_OPEN_PROXY = false diff --git a/.env.production b/.env.production index fe5c47d..2f97f31 100644 --- a/.env.production +++ b/.env.production @@ -6,6 +6,8 @@ VITE_APP_TITLE = 页面标题 VITE_APP_API_BASEURL = / # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空 VITE_APP_DEBUG_TOOL = +# 是否禁用开发者工具,可防止被调试 +VITE_APP_DISABLE_DEVTOOL = false # 是否在打包时启用 Mock VITE_BUILD_MOCK = false diff --git a/.env.test b/.env.test index a5df7d2..5e56db7 100644 --- a/.env.test +++ b/.env.test @@ -6,6 +6,8 @@ VITE_APP_TITLE = 页面标题(test) VITE_APP_API_BASEURL = / # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空 VITE_APP_DEBUG_TOOL = +# 是否禁用开发者工具,可防止被调试 +VITE_APP_DISABLE_DEVTOOL = false # 是否在打包时启用 Mock VITE_BUILD_MOCK = true diff --git a/package.json b/package.json index 4501e6a..efedb08 100755 --- a/package.json +++ b/package.json @@ -30,6 +30,7 @@ "axios": "^1.7.2", "dayjs": "^1.11.11", "defu": "^6.1.4", + "disable-devtool": "^0.3.7", "element-plus": "^2.7.5", "eruda": "^3.0.1", "floating-vue": "5.2.2", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 18a9751..d9d3773 100755 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -19,7 +19,7 @@ importers: version: 10.11.0(vue@3.4.29(typescript@5.4.5)) '@vueuse/integrations': specifier: ^10.11.0 - version: 10.11.0(async-validator@4.2.5)(axios@1.7.2)(change-case@5.4.4)(nprogress@0.2.0)(vue@3.4.29(typescript@5.4.5)) + version: 10.11.0(async-validator@4.2.5)(axios@1.7.2)(change-case@4.1.2)(nprogress@0.2.0)(vue@3.4.29(typescript@5.4.5)) axios: specifier: ^1.7.2 version: 1.7.2 @@ -29,6 +29,9 @@ importers: defu: specifier: ^6.1.4 version: 6.1.4 + disable-devtool: + specifier: ^0.3.7 + version: 0.3.7 element-plus: specifier: ^2.7.5 version: 2.7.5(vue@3.4.29(typescript@5.4.5)) @@ -2495,9 +2498,6 @@ packages: change-case@4.1.2: resolution: {integrity: sha512-bSxY2ws9OtviILG1EiY5K7NNxkqg/JnRnFxLtKQ96JaviiIxi7djMrSd0ECT9AC+lttClmYwKw53BWpOMblo7A==} - change-case@5.4.4: - resolution: {integrity: sha512-HRQyTk2/YPEkt9TnUPbOpr64Uw3KOicFWPVBb+xiHvd6eBx/qPr9xqfBFDT8P2vWsvvz4jbEkfDe71W3VyNu2w==} - character-entities-legacy@1.1.4: resolution: {integrity: sha512-3Xnr+7ZFS1uxeiUDvV02wQ+QDbc55o97tIV5zHScSPJpcLm/r0DFPcoY3tYRp+VZukxuMeKgXYmsXQHO05zQeA==} @@ -2864,6 +2864,9 @@ packages: resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==} engines: {node: '>=8'} + disable-devtool@0.3.7: + resolution: {integrity: sha512-xF5uyEpBhDuy7b4Bb88GQG4IB+2CwuQfkJK9vB/ym+85NQp/f7Wc6hnT40Jy2SkKvEf1xAKpvJUJU3LykTXxKg==} + doctrine@3.0.0: resolution: {integrity: sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==} engines: {node: '>=6.0.0'} @@ -8234,7 +8237,7 @@ snapshots: - '@vue/composition-api' - vue - '@vueuse/integrations@10.11.0(async-validator@4.2.5)(axios@1.7.2)(change-case@5.4.4)(nprogress@0.2.0)(vue@3.4.29(typescript@5.4.5))': + '@vueuse/integrations@10.11.0(async-validator@4.2.5)(axios@1.7.2)(change-case@4.1.2)(nprogress@0.2.0)(vue@3.4.29(typescript@5.4.5))': dependencies: '@vueuse/core': 10.11.0(vue@3.4.29(typescript@5.4.5)) '@vueuse/shared': 10.11.0(vue@3.4.29(typescript@5.4.5)) @@ -8242,7 +8245,7 @@ snapshots: optionalDependencies: async-validator: 4.2.5 axios: 1.7.2 - change-case: 5.4.4 + change-case: 4.1.2 nprogress: 0.2.0 transitivePeerDependencies: - '@vue/composition-api' @@ -8672,9 +8675,6 @@ snapshots: snake-case: 3.0.4 tslib: 2.6.2 - change-case@5.4.4: - optional: true - character-entities-legacy@1.1.4: {} character-entities@1.2.4: {} @@ -9022,6 +9022,8 @@ snapshots: dependencies: path-type: 4.0.0 + disable-devtool@0.3.7: {} + doctrine@3.0.0: dependencies: esutils: 2.0.3 diff --git a/src/App.vue b/src/App.vue index 054a112..aad89d0 100755 --- a/src/App.vue +++ b/src/App.vue @@ -1,6 +1,7 @@