未验证 提交 4c740504 编写于 作者: fxy060608's avatar fxy060608 提交者: GitHub

Merge pull request #1695 from iqshen/master

修复百度小程序下mounted可能不执行的问题
export const mocks = ['nodeId', 'componentName', '_componentId', 'uniquePrefix']
export function isPage () {
return !this.ownerId
// 百度小程序组件的id,某些情况下可能是number类型的0,不能直接return !this.ownerId 判断当前组件是否是Page
// 否则会导致mounted不执行
return typeof this.ownerId === 'undefined'
}
export function initRelation (detail) {
this.dispatch('__l', detail)
}
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册