Skip to content

Commit

Permalink
fix: Remove attribute instead of raise it when bindings parser is use…
Browse files Browse the repository at this point in the history
…d on HTML5 form elements

This change fixes a bug which appears when bindings parser is used on 'checked' attribute of a

checkbox and bound property is undefined
finom committed Oct 4, 2016

Verified

This commit was signed with the committer’s verified signature.
re-taro Rintaro Itokawa
1 parent d3c4223 commit dd5039f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/parsebindings/_processattribute/index.js
Original file line number Diff line number Diff line change
@@ -38,7 +38,7 @@ export default function processAttribute({
if (defaultBinder) {
// if deault binder is found then this is default HTML5 form element
// remove the attribute and use found binder
node.setAttribute(name, '');
node.removeAttribute(name);
bindNode(object, key, node, defaultBinder, eventOptions);
} else {
// simply bind an attribute

0 comments on commit dd5039f

Please sign in to comment.