Why i can't remove items of the array?
The html view here i am trying to display all objects of the array Edit here every time you click at the tag i want to remove an element of the array. but it is not working Delete
the script
$(function () {
var customers=[
{name:'robert'},
{name:'miguel'},
{name:'felipe'},
{name:'juan'},
{name:'danilo'},
{name:'federico'}
];
var viewModel = {
self:this,
list: ko.observableArray(customers),
its not removing the item of the array.
removeItem: function(place) {
this.list.remove(place);
}
};
ko.applyBindings(viewModel);
});
Aucun commentaire:
Enregistrer un commentaire