defineStore actions 'this' is typed 'any' #965
Answered
by
nurdism
nurdism
asked this question in
Help and Questions
-
I'm using this in a nuxt3 project and I'm running https://i.imgur.com/PmDrHv5.png import { defineStore } from 'pinia'
export const useApplicationStore = defineStore({
id: 'applicationStore',
state: () => ({
id: '',
}),
actions: {
reset() {
this.id = ''
},
},
}) |
Beta Was this translation helpful? Give feedback.
Answered by
nurdism
Mar 1, 2022
Replies: 2 comments
-
Same problem. Any solution? |
Beta Was this translation helpful? Give feedback.
0 replies
-
I ended opening up an issue about it #981 |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
nurdism
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I ended opening up an issue about it #981
{ strict: true }
or try{ noImplicitThis: true }
in your TS config.