Typescript Array Slice Vs Splice Javascript Syntax For Opening