JavaScript can be used to create an array that can potentially have all available types in it. We can use the spread operator to copy an array in JS like spreading it ( […array] ), using array.concat() , Array.from(array) or array.slice() but it will fail at run time. If you are using eslint together with TS you might have noticed the message unexpected any .
3 Comments
Sort: