David Morrow
David Morrow
the underlying problem seems to be in `_.uniq` as `_.union` is merely a wrapper function for unique and flatten. ``` javascript _.union = restArgs(function(arrays) { return _.uniq(flatten(arrays, true, true)); });...
or something along the lines of `_.isCollection` to determine if you are dealing with a collection. If dealing with a collection, then the comparisons should use `_.isEqual` instead of `===`...
@jdalton good point on the comparisons, but wouldn't you usually use a key for unique on a collection rather than forcing Underscore to detect the entire difference between the objects?...
right, thats my point, the above code works currently as posted. could't you just call uniq / unique with a key on the result of the union?
ok, gotcha, sorry... Im not trying to be belligerent, just wanted to totally understand the problem. Id love to submit a pull request on the `_.uniqWith` function.
ok so additional comparison function parameters are the way to go here then? If so I can update my pull request. the only tricky part I forsee is making the...
have updated this pull request #2368 thanks.
should I pull request on Lodash with the separate method then? I thought the two projects merged, am i mistaken?
Im sure there is an excellent reason for this, _and id love to hear it_ but wouldn't it save quite a bit of size if Underscore used more of its...
Im willing to attempt a PR on this, i have verified the issue reported above. example ```html ``` when converted to hyperscript and then rendered to the DOM, the `data-id`...