[Vuejs]-Updating data from a component

0👍

The variable someVal in your filter is not defined so it will return the same items.

To remove an item you could use the splice() function.

Example:

remove: function(index) {
    this.data = this.data.splice(index, 1);
}

In your template use something like this:

<div v-for="(item, index) in data" @click="remove(index)"></div>

Leave a comment