Fuse icon indicating copy to clipboard operation
Fuse copied to clipboard

fix: FuseSortFunctionMatch typescript types

Open hoonoh opened this issue 3 years ago • 1 comments

Relates to #613

Fixes typing on FuseSortFunctionMatch, mainly on key & indices attribute. I included typings test which triggers searchFn with and without includeMatches option, which when undefined, the indices attribute type is also undefined. I am not sure if this change should bring any side effects, or if the typing on FuseSortFunctionMatch should be different when Fuse constructor is given different option combinations from the ones in the added tests.

hoonoh avatar May 16 '22 12:05 hoonoh

Thanks for the PR! Let me dig into this a bit more. Want to ensure there is no side effect.

krisk avatar May 18 '22 02:05 krisk