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

fix(mp-baidu): mpType

上级 b6e16bdb
......@@ -1067,7 +1067,7 @@ function handleLink(event) {
const mocks = ['nodeId', 'componentName', '_componentId', 'uniquePrefix'];
function isPage(mpInstance) {
return !hasOwn(mpInstance, 'ownerId');
return !!mpInstance.methods.onLoad;
}
function initRelation(mpInstance, detail) {
mpInstance.dispatch('__l', detail);
......
......@@ -17,7 +17,7 @@ export { handleLink, initLifetimes } from '@dcloudio/uni-mp-weixin'
export const mocks = ['nodeId', 'componentName', '_componentId', 'uniquePrefix']
export function isPage(mpInstance: MPComponentInstance) {
return !hasOwn(mpInstance, 'ownerId')
return !!(mpInstance.methods as any).onLoad
}
export function initRelation(mpInstance: MPComponentInstance, detail: object) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册