Hello,
I'm trying to bind the selected item in a tree to an object in my ViewModel and I fail to do that.
I tried to use this in my markup:
<div class="todo-tree" data-bind="source: todoList, value: selectedTask" ></div>
But I guess it is not the correct way, since I get the following error:
Uncaught TypeError: Object [object Object] has no method 'value'
I that matters, my data source is a simple array.
Did anyone did that before and can assist?
Thanks,
Irit
I'm trying to bind the selected item in a tree to an object in my ViewModel and I fail to do that.
I tried to use this in my markup:
<div class="todo-tree" data-bind="source: todoList, value: selectedTask" ></div>
But I guess it is not the correct way, since I get the following error:
Uncaught TypeError: Object [object Object] has no method 'value'
I that matters, my data source is a simple array.
Did anyone did that before and can assist?
Thanks,
Irit