4 ms·
True, but does not mean the type of the array that should be built should be of different types. I think the sane definition by Typescript is that it should be
by funkaster 8y ago
True, but does not mean the type of the array that should be built should be of different types. I think the sane definition by Typescript is that it should be of the same type: that's why it's an instance method and not a static one. If this was a static method (Array.concat(a, b)), I would agree that would be a good assumption, that the type of the resulting array should be union of the types of the arguments.