Closed getify closed 2 years ago
Current proposal is minimal, only support Array and TypedArray. I think we should also support Tuple when it landed.
Note String is not supported due to unicode surrogate issue. Though I'm considering some possible solutions in follow-on proposal.
It's possible to extend to other objects in the future, but consider this proposal include negative index (or use index form end syntax instead), length
property would be required, so at least it should be ArrayLike. Anyway, we could always use Array.from(arrayLike)[3:5]
.
Is this supported?