提交 eb30d2a5 编写于 作者: Q qiang

build runtime

上级 a6494ea3
......@@ -2106,6 +2106,14 @@ function parsePage (vuePageOptions) {
};
initHooks(pageOptions, hooks$1, vuePageOptions);
if (Array.isArray(vueOptions.wxsCallMethods)) {
vueOptions.wxsCallMethods.forEach(callMethod => {
pageOptions[callMethod] = function (args) {
return this.$vm[callMethod](args)
};
});
}
return pageOptions
}
......@@ -2221,6 +2229,14 @@ function parseComponent (vueComponentOptions) {
componentOptions.deriveDataFromProps = createObserver$1();
} else {
componentOptions.didUpdate = createObserver$1(true);
}
if (Array.isArray(vueOptions.wxsCallMethods)) {
vueOptions.wxsCallMethods.forEach(callMethod => {
componentOptions.methods[callMethod] = function (args) {
return this.$vm[callMethod](args)
};
});
}
return componentOptions
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册