es-toolkit
es-toolkit copied to clipboard
feat(orderBy, sortBy): support custom key functions in `orderBy` and integrate `sortBy` with `orderBy`
Description
orderBy
- I add a feature of custom key functions in
orderBy. - I changed handling a case that the number of orders is less than the number of criteria, for performance.
- And I also integrate signature and docs based on
sortBy.
sortBy
Two functions are very similar, so I integrate sortBy with orderBy.
Benchmarks
reopen #398 (I delete Repository that had the PR's branch by mistake. So I create new PR.) close #383
The latest updates on your projects. Learn more about Vercel for Git ↗︎
| Name | Status | Preview | Comments | Updated (UTC) |
|---|---|---|---|---|
| es-toolkit | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Aug 21, 2024 1:34am |
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 99.77%. Comparing base (
5c551b8) to head (6fb81a4).
Additional details and impacted files
@@ Coverage Diff @@
## main #407 +/- ##
==========================================
- Coverage 99.77% 99.77% -0.01%
==========================================
Files 161 161
Lines 1323 1317 -6
Branches 358 357 -1
==========================================
- Hits 1320 1314 -6
Misses 2 2
Partials 1 1