S-array
S-array copied to clipboard
Adding a Symbol.iterator property
Hey Adam,
would it be possible to add a Symbol.iterator property for better interop?
For example, with SArrays the following fails with a .map() is not iterable error:
const arr = SArray([1, 2, 3, 3, 4, 5]);
const set = new Set(arr.map(i => i > 2));
Thanks!