Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

angular remove element from array

removeElement(data:any){
    const index: number = this.list.indexOf(data);
    if (index !== -1) {
        this.list.splice(index, 1);
    } 
  }
 
PREVIOUS NEXT
Tagged: #angular #remove #element #array
ADD COMMENT
Topic
Name
2+4 =