Sid Gifari File Manager
🏠 Root
/
home
/
genremedia08
/
musicjukebox.overlookedtracks.com
/
common
/
resources
/
client
/
utils
/
array
/
Editing: move-item-in-new-array.ts
export function moveItemInNewArray<T>( array: T[], from: number, to: number ): T[] { const newArray = array.slice(); newArray.splice( to < 0 ? newArray.length + to : to, 0, newArray.splice(from, 1)[0] ); return newArray; }
Save
Cancel