knockout.toggle
v2.0.0
Published
Knockout binding to toggle boolean view model properties
Downloads
8
Readme
Knockout Toggle Binding
Knockout binding to toggle boolean view model properties.
Installation
npm install knockout-toggle
Usage
Include the script with your module bundler, then use the binding like so:
<button data-bind="toggle: myProp">Toggle the thing</button>
<span data-bind="visible: myProp">It's ON</span>