feat(compile-core): handle falsy dynamic args for v-on and v-bind (#2393)
fix #2388
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { isObject, capitalize } from '@vue/shared'
|
||||
import { toHandlerKey, isObject } from '@vue/shared'
|
||||
import { warn } from '../warning'
|
||||
|
||||
/**
|
||||
@@ -12,7 +12,7 @@ export function toHandlers(obj: Record<string, any>): Record<string, any> {
|
||||
return ret
|
||||
}
|
||||
for (const key in obj) {
|
||||
ret[`on${capitalize(key)}`] = obj[key]
|
||||
ret[toHandlerKey(key)] = obj[key]
|
||||
}
|
||||
return ret
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user