Answers for "delete a row from array javascript"

0

remove row from array javascript

// main array
let array = ['item 1', 'item 2', 'item 3'];

// adding new item at 2nd place / 1st index
array.splice(1, 0, 'new item 1');

// removing single item and return it from 3rd place / 2nd index
array.splice(2, 1);
Posted by: Guest on February-09-2022

Code answers related to "delete a row from array javascript"

Code answers related to "Javascript"

Browse Popular Code Answers by Language