JSFiddle - React, Tailwind, and code Playground

by fastfasterfastest

HTML

<script src="https://unpkg.com/[email protected]/build/output/knockout-latest.debug.js"></script>
<h2>v3.5.0</h2>
<div id="test1"></div>

JavaScript

ko.applyBindings({
            test: ko.observable("Test")
        });
        var newDiv = document.createElement("div");
        document.getElementById("test1").appendChild(newDiv);
        var context = ko.contextFor(newDiv);
       alert(context===undefined); 
       alert(context===null); alert(JSON.stringify(context.$root.test()))