Skip to content

Binding in checkBoxValue when value in model is undefined. #45

Description

@hynekmusil

Example see : https://jsfiddle.net/ee424v3e/12/

My code modification:
Bacon.$.checkBoxValue = function(element, initValue) {
return Bacon.Binding({
initValue: initValue,
get: function() {
return element.prop("checked") || false;
},
events: element.asEventStream("change"),
set: function(value) {
return element.prop("checked", value || false);
}
});
};

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions