kentcdodds / match-sorter

Simple, expected, and deterministic best-match sorting of an array in JavaScript
https://npm.im/match-sorter
MIT License
3.73k stars 129 forks source link

feat: add baseSort configuration option #95

Closed tannerlinsley closed 4 years ago

tannerlinsley commented 4 years ago

What: Added a baseSort configuration option

Why: Ability to override the default stable sort for tie-breaker items

How: By adding a new configuration option and implementing some inversion of control and a new default

Checklist:

tannerlinsley commented 4 years ago

@all-contributors please add tannerlinsley for code

allcontributors[bot] commented 4 years ago

@tannerlinsley

I've put up a pull request to add @tannerlinsley! :tada:

codecov[bot] commented 4 years ago

Codecov Report

Merging #95 into master will not change coverage. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##            master       #95   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            1         1           
  Lines          152       156    +4     
  Branches        39        38    -1     
=========================================
+ Hits           152       156    +4     
Impacted Files Coverage Δ
src/index.js 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 8c2cbc7...55ceeeb. Read the comment docs.

tannerlinsley commented 4 years ago

Looks like the test failed, but I can't really decipher why.

kentcdodds commented 4 years ago

Thanks!

kentcdodds commented 4 years ago

:tada: This PR is included in version 4.2.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: