enumerable
enumerable copied to clipboard
Preserve collection type when filtering?
Would it be a bad idea to ensure that in the following example, given that collection is an instance of an Enumerable subtype, filteredCollection is of the same type instead of being a vanilla Enumerable?
var filteredCollection = collection.select(predicate)
Or another way to put it: Would it be reasonable to change https://github.com/component/enumerable/blob/master/index.js#L163
into new this.constructor(arr)?