Skip to content

Commit

Permalink
chore: fixup type errors
Browse files Browse the repository at this point in the history
  • Loading branch information
posva committed Sep 30, 2024
1 parent 249d5c4 commit 40275cf
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/pinia/src/mapHelpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,7 @@ export function mapState<
? keysOrMapper.reduce(
(reduced, key) => {
reduced[key] = function (this: ComponentPublicInstance) {
// @ts-expect-error: FIXME: should work?
return useStore(this.$pinia)[key]
} as () => any
return reduced
Expand All @@ -285,7 +286,8 @@ export function mapState<
this,
store
)
: store[storeKey]
: // @ts-expect-error: FIXME: should work?
store[storeKey]
}
return reduced
},
Expand Down

0 comments on commit 40275cf

Please sign in to comment.