rtfeldman / seamless-immutable

Immutable data structures for JavaScript which are backwards-compatible with normal JS Arrays and Objects.
BSD 3-Clause "New" or "Revised" License
5.36k stars 194 forks source link

SortBy Implementation #273

Open ivportilla opened 4 years ago

ivportilla commented 4 years ago

Based on the issue #182 i have created a sortBy function based on the current behavior of Lodash and Ramda.

Please feel free to reply with feedback and i will be pending of it in order to make the changes that you think that have to be made.

Documentation and unit tests cover the case uses.

Note: I am also planning to add a sortWith which will accept the sorter and reimplement sortBy using sortWith.