Array.prototype.orderItems = function(newer, older) { var list = new Array(...this) return list.splice(newer - 1, 0, ...list.splice(older, 1)) }