@@ -311,7 +311,7 @@ router.beforeEach((to, from, next) => {
// 全局后置钩子,设置title
router.afterEach(to => {
// 设置title
- document.title = to.meta.myTitle;
+ window.document.title = to.meta.myTitle;
})
@@ -38,7 +38,7 @@ export default {
if (v.id === id) this.data = v;
});
setTimeout(() => {
- document.title = this.data.h3;
+ window.document.title = this.data.h3;
}, 100);
},
beforeCreate() {}, //生命周期 - 创建之前
@@ -64,7 +64,7 @@ export default {
if (k === temp) temp = this.mate[k];
}
- document.title = temp;
+ window.document.title = temp;
this.txt = temp;
@@ -214,7 +214,7 @@ export default {
this.$nextTick(() => {
// 改变网址title
- document.title = this.data.title;
+ window.document.title = this.data.title;
let tempArr = this.data.page;
let dom = document.querySelector(".card");
@@ -73,7 +73,7 @@ export default {
if (v.id === id) this.data = v.info;
- document.title = "Exhibition Galleries";
+ window.document.title = "Exhibition Galleries";
- document.title = 'Exhibition Objects';
+ window.document.title = 'Exhibition Objects';
@@ -46,7 +46,7 @@ export default {
@@ -52,7 +52,7 @@ export default {
@@ -36,7 +36,7 @@ export default {
- document.title = this.info.p;
+ window.document.title = this.info.p;
//生命周期 - 挂载完成(可以访问DOM元素)
@@ -67,7 +67,7 @@ export default {
let dom = document.querySelector(".Layout .bottom");
dom.style.display = "none";
- document.title = this.info.name;
+ window.document.title = this.info.name;
// 获取顶部固定栏
let LayoutTop = document.querySelector(".Layout .top");
LayoutTop.style.display = "none";