Remove one element by index from JavaScript array
I was hunting around for this and eventually found it, but it seemed slightly hard to find this specific case…so here’s how:
myArray.splice(myIndex, 1);
Enjoy.
I was hunting around for this and eventually found it, but it seemed slightly hard to find this specific case…so here’s how:
myArray.splice(myIndex, 1);
Enjoy.