When I started using knockout.js in my applications I became excited to see the many uses of this library. It took me a little bit of time to realize how to implement it. One reason it took me a while was when I came across this error.
Unable to get value of the property nodeType
I checked and rechecked my syntax and spent several days trying to find the problem. Come to find out it was a simple solution. Although you can get this error for many reasons one of the easiest reasons is that your code file that initializes the knockout.js binding is trying to load before the knockout library has completely loaded. So if you move your binding towards the end of the page while loading the knockout.js library near the top, this is generally enough time for everything to load appropriately.
This is just a quick resolution to a simple problem. An example is below.
[sourcecode language=”html”]<br />
<!DOCTYPE html><br />
<head><br />
<title></title><br />
<script src="jquery-1.8.3.min.js"></script><br />
<script src="knockout-latest.js"></script><br />
</head></p>
<p><body><br />
<form id="form1" runat="server"><br />
<div><br />
……….Code…………….<br />
</div><br />
</form></p>
<p> <script src="dropdown.js"></script><br />
</body></p>
<p></html><br />
[/sourcecode]
Looking for quality web hosting? Look no further than Arvixe Web Hosting!