Skip to content

Commit

Permalink
fix: add generic argument for distinct-array util
Browse files Browse the repository at this point in the history
  • Loading branch information
tada5hi committed May 20, 2023
1 parent 240ce25 commit 4d31b24
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utils/array.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

import { isEqual } from './check';

export function distinctArray(arr: any[]) : any[] {
export function distinctArray<T = any>(arr: T[]) : T[] {
const copy = [...arr];

for (let i = 0; i < copy.length; i++) {
Expand Down

0 comments on commit 4d31b24

Please sign in to comment.