Open
Description
- I'm submitting a ...
[x] bug report
[ ] feature request
[ ] question about the decisions made in the repository
[x] question about how to use this project
I have this page
component in nuxt
:
@Component({})
export default class Index extends mixins(TypedStoreMixin) {
fetch ({ store }: { store }): Promise<RawCommentType[]> {
// Here we don't have a DI setup yet, so we use the explicit approach:
const typedStore = useStore<TypedStore>(store)
return typedStore.comments.fetchComments()
}
fetchComments () {
this.typedStore.comments.fetchComments()
}
}
When I use fetch
method from Nuxt I see this error:
Cannot determine a class of the requesting service "function TestService() {}"
But, if fetch
is not used and I instead use fetchComments
method on button click - it works fine.
I guess the reason is that nuxt
handles fetch
differently and something is not setup properly.
Metadata
Metadata
Assignees
Labels
No labels