Skip to content

Commit

Permalink
Merge pull request #7 from giraugh/fix/merge-object-values-types
Browse files Browse the repository at this point in the history
Fix types of mergeObjectValuesBy
  • Loading branch information
giraugh authored Apr 20, 2023
2 parents 357817c + f788708 commit 03837df
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/honest-parents-fetch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@giraugh/tools": patch
---

Fix type of TOBJ in mergeObjectValuesBy being unuseable with interfaces
2 changes: 1 addition & 1 deletion lib/objects/mergeObjectValuesBy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
*/
export const mergeObjectValuesBy = <
TKeys extends PropertyKey,
TObj extends Record<TKeys, unknown>
TObj extends Record<TKeys, any>
>(
objects: TObj[],
mergeFn: (a: TObj[TKeys], b: TObj[TKeys]) => TObj[TKeys]
Expand Down

0 comments on commit 03837df

Please sign in to comment.