Lets say I have a ViewModel (pseudo code):
MyViewModel​: ObservableObject {
myItems: ObservableArray<MyItemViewModel>
}
MyItemViewModel: ObservableObject {
myFunction: function() {
// Some code here...
}
}
Then, if I make an instance of MyViewModel the dataSource of Kendo Grid, what would the syntax for mapping each row's custom command to myFunction be? I can (as in examples) map to inline function that will then find nearest tr and it's dataItem, then call the function - but I would rather like it (if possible) to map it directly to the function of each row's ViewModel... Any ideas?
Thanks in advance.