diff --git a/packages/taro-with-weapp/src/index.ts b/packages/taro-with-weapp/src/index.ts index 76c78772aa22..57d54d0d7484 100644 --- a/packages/taro-with-weapp/src/index.ts +++ b/packages/taro-with-weapp/src/index.ts @@ -83,7 +83,8 @@ export default function withWeapp (componentType: string) { if (typeof eventName !== 'string') { throw new Error('triggerEvent 第一个参数必须是字符串') } - super.$scope.triggerEvent(eventName.toLowerCase(), ...args) + const fullEventName = `on${eventName}` + this.$scope.triggerEvent(fullEventName.toLowerCase(), ...args) } componentWillReceiveProps (nextProps) {