typewscript create new array reference code example Example: copy array typescript let myClonedArray: Array<Type> = [...myArray];