提交 08553523 编写于 作者: D DCloud_LXH

chore: handleEvent error parse

上级 8ee40d97
......@@ -556,7 +556,9 @@ export function handleEvent (event) {
}
const handler = handlerCtx[methodName]
if (!isFn(handler)) {
throw new Error(` _vm.${methodName} is not a function`)
const type = this.$vm.mpType === 'page' ? 'Page' : 'Component'
const path = this.route || this.is
throw new Error(`${type} "${path}" does not have a method "${methodName}"`)
}
if (isOnce) {
if (handler.once) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册