From e9405fc5a1e80d40cad9cfaa7a56a5078b55c30e Mon Sep 17 00:00:00 2001 From: 潘志宝 <979469083@qq.com> Date: 星期五, 07 三月 2025 08:52:12 +0800 Subject: [PATCH] Merge branch 'master' of http://dlindusit.com:53929/r/iailab-plat-ui-vue3 --- /dev/null | 23 ----------------------- src/main.ts | 1 - 2 files changed, 0 insertions(+), 24 deletions(-) diff --git a/src/main.ts b/src/main.ts index ed098e4..90aceba 100644 --- a/src/main.ts +++ b/src/main.ts @@ -50,7 +50,6 @@ import './permission' -import '@/plugins/tongji' // 百度统计 import Logger from '@/utils/Logger' import VueDOMPurifyHTML from 'vue-dompurify-html' // 解决v-html 的安全隐患 diff --git a/src/plugins/tongji/index.ts b/src/plugins/tongji/index.ts deleted file mode 100644 index ec261a1..0000000 --- a/src/plugins/tongji/index.ts +++ /dev/null @@ -1,23 +0,0 @@ -import router from '@/router' - -// 用于 router push -window._hmt = window._hmt || [] -// HM_ID -const HM_ID = import.meta.env.VITE_APP_BAIDU_CODE -;(function () { - // 有值的时候,才开启 - if (!HM_ID) { - return - } - const hm = document.createElement('script') - hm.src = 'https://hm.baidu.com/hm.js?' + HM_ID - const s = document.getElementsByTagName('script')[0] - s.parentNode.insertBefore(hm, s) -})() - -router.afterEach(function (to) { - if (!HM_ID) { - return - } - _hmt.push(['_trackPageview', to.fullPath]) -}) -- Gitblit v1.9.3