refactor(runtime-core): adjust attr fallthrough behavior
BREAKING CHANGE: adjust attr fallthrough behavior
Updated per pending RFC https://github.com/vuejs/rfcs/pull/137
- Implicit fallthrough now by default only applies for a whitelist
of attributes (class, style, event listeners, a11y attributes, and
data attributes).
- Fallthrough is now applied regardless of whether the component has
explicitly declared props. (close #749)
This commit is contained in:
@@ -214,7 +214,7 @@ export function resolveProps(
|
||||
lock()
|
||||
|
||||
instance.props = props
|
||||
instance.attrs = options ? attrs || EMPTY_OBJ : props
|
||||
instance.attrs = attrs || EMPTY_OBJ
|
||||
instance.vnodeHooks = vnodeHooks || EMPTY_OBJ
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user