Splicing a string indexed array in JavaScript

The proper way to do this is not with an Array but an object:

var x = {};
x['Zero'] = 'Zero';
x['One'] = 'One';
x['Two'] = 'Two';
console.log(x); //  Object Zero=Zero One=One Two=Two
delete x['One'];
console.log(x); //  Object Zero=Zero Two=Two

Once an Array has string keys (or numbers that don't follow), it becomes an Object.

An object doesn't have the splice method (or not the same as Array). You have to write your own, by making a new object and copy into it the key you want to keep.

But be careful ! The keys are not always ordered in the same way they were added in the object ! It depends on the browser.