JSFiddle - React, Tailwind, and code Playground
by johnhunter
HTML
<script src="//code.jquery.com/jquery-1.7.2.js"></script>
<script src="//knockoutjs.com/js/knockout-2.1.0.js"></script>
<div data-bind="template: 'test-template'"></div>
<script type="text/html" id="test-template">
<p>template rendered</p>
<!-- ko if: testval -->
<p>testval true</p>
<!-- /ko -->
</script>
<script>
/*
Note: native binding style causes IE7 memory leak even if observable is not altered.
*/
var vm = {
testval: ko.observable(false)
};
setTimeout(function(){
vm.testval(true);
}, 1000);
ko.applyBindings(vm);
</script>