The viewmodel should get undefined when a model hasn't been provided using data-model=""
The nested viewmodel shouldn't be called with a third argument, since that makes it difficult to reuse the viewmodel. It shouldn't sometimes get two arguments and sometimes three.
Instead of providing the parent viewmodel as the third argument to a nested viewmodel, provide the option to supply parameters, almost like a component. Do this using the data-params attribute
cleanNode cleans up after jQuery as well, when all we want is for knockout to forget about the currently bound viewmodel.
Merge branch 'nested-vm-params'
Fixed bug #19, where a non-existing function was called on the whenContext.
Made sure to use the associative array accessor when calling Promise catch, since catch is a reserved word in IE8
Merge branch 'fix-19-cleanNestedVM'