提交 cfa0ae46 编写于 作者: fxy060608's avatar fxy060608

npm run build:runtime

上级 a653b7bf
......@@ -1134,10 +1134,10 @@ const hooks = [
function parseBaseApp (vm, {
mocks,
initRefs
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
Vue.prototype.mpHost = "app-plus";
......@@ -1178,8 +1178,8 @@ function parseBaseApp (vm, {
app: this
};
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.globalData = this.globalData;
this.$vm._isMounted = true;
......@@ -1191,6 +1191,13 @@ function parseBaseApp (vm, {
// 兼容旧版本 globalData
appOptions.globalData = vm.$options.globalData || {};
// 将 methods 中的方法挂在 getApp() 中
const methods = vm.$options.methods;
if (methods) {
Object.keys(methods).forEach(name => {
appOptions[name] = methods[name];
});
}
initHooks(appOptions, hooks);
......
......@@ -1526,10 +1526,10 @@ const hooks = [
function parseBaseApp (vm, {
mocks,
initRefs
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
Vue.prototype.mpHost = "mp-alipay";
......@@ -1570,8 +1570,8 @@ function parseBaseApp (vm, {
app: this
};
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.globalData = this.globalData;
this.$vm._isMounted = true;
......@@ -1583,6 +1583,13 @@ function parseBaseApp (vm, {
// 兼容旧版本 globalData
appOptions.globalData = vm.$options.globalData || {};
// 将 methods 中的方法挂在 getApp() 中
const methods = vm.$options.methods;
if (methods) {
Object.keys(methods).forEach(name => {
appOptions[name] = methods[name];
});
}
initHooks(appOptions, hooks);
......
......@@ -1271,10 +1271,10 @@ const hooks = [
function parseBaseApp (vm, {
mocks,
initRefs
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
Vue.prototype.mpHost = "mp-baidu";
......@@ -1315,8 +1315,8 @@ function parseBaseApp (vm, {
app: this
};
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.globalData = this.globalData;
this.$vm._isMounted = true;
......@@ -1328,6 +1328,13 @@ function parseBaseApp (vm, {
// 兼容旧版本 globalData
appOptions.globalData = vm.$options.globalData || {};
// 将 methods 中的方法挂在 getApp() 中
const methods = vm.$options.methods;
if (methods) {
Object.keys(methods).forEach(name => {
appOptions[name] = methods[name];
});
}
initHooks(appOptions, hooks);
......
......@@ -1189,10 +1189,10 @@ const hooks = [
function parseBaseApp (vm, {
mocks,
initRefs
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
Vue.prototype.mpHost = "mp-qq";
......@@ -1238,8 +1238,8 @@ function parseBaseApp (vm, {
app: this
};
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.globalData = this.globalData;
this.$vm._isMounted = true;
......@@ -1251,6 +1251,13 @@ function parseBaseApp (vm, {
// 兼容旧版本 globalData
appOptions.globalData = vm.$options.globalData || {};
// 将 methods 中的方法挂在 getApp() 中
const methods = vm.$options.methods;
if (methods) {
Object.keys(methods).forEach(name => {
appOptions[name] = methods[name];
});
}
initHooks(appOptions, hooks);
......
......@@ -1281,10 +1281,10 @@ const hooks = [
function parseBaseApp (vm, {
mocks,
initRefs
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
Vue.prototype.mpHost = "mp-toutiao";
......@@ -1325,8 +1325,8 @@ function parseBaseApp (vm, {
app: this
};
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.globalData = this.globalData;
this.$vm._isMounted = true;
......@@ -1338,6 +1338,13 @@ function parseBaseApp (vm, {
// 兼容旧版本 globalData
appOptions.globalData = vm.$options.globalData || {};
// 将 methods 中的方法挂在 getApp() 中
const methods = vm.$options.methods;
if (methods) {
Object.keys(methods).forEach(name => {
appOptions[name] = methods[name];
});
}
initHooks(appOptions, hooks);
......
......@@ -1129,10 +1129,10 @@ const hooks = [
function parseBaseApp (vm, {
mocks,
initRefs
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
}) {
if (vm.$options.store) {
Vue.prototype.$store = vm.$options.store;
}
Vue.prototype.mpHost = "mp-weixin";
......@@ -1178,8 +1178,8 @@ function parseBaseApp (vm, {
app: this
};
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.$scope = this;
// vm 上也挂载 globalData
this.$vm.globalData = this.globalData;
this.$vm._isMounted = true;
......@@ -1191,6 +1191,13 @@ function parseBaseApp (vm, {
// 兼容旧版本 globalData
appOptions.globalData = vm.$options.globalData || {};
// 将 methods 中的方法挂在 getApp() 中
const methods = vm.$options.methods;
if (methods) {
Object.keys(methods).forEach(name => {
appOptions[name] = methods[name];
});
}
initHooks(appOptions, hooks);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册