Skip to content

Commit

Permalink
fix(types): storeToRefs with nested refs (#2659)
Browse files Browse the repository at this point in the history
Co-authored-by: Vadim Kruglov <[email protected]>
  • Loading branch information
quiteeasy and Vadim Kruglov authored Sep 26, 2024
1 parent 7a0e841 commit 623e5a0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/pinia/src/storeToRefs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ import type {
} from './types'

type ToComputedRefs<T> = {
[K in keyof T]: ToRef<T[K]> extends Ref<infer U>
? ComputedRef<U>
[K in keyof T]: ToRef<T[K]> extends Ref
? ComputedRef<T[K]>
: ToRef<T[K]>
}

Expand Down

0 comments on commit 623e5a0

Please sign in to comment.