Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

delete item from list javascript

const array = [1, 2, 3];
const index = array.indexOf(2);
if (index > -1) {
  array.splice(index, 1);
}
 
PREVIOUS NEXT
Tagged: #delete #item #list #javascript
ADD COMMENT
Topic
Name
9+2 =