Use Javascript In Typescript Array Sorting