Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERR_STORE_NOT_PROVIDED when using named namespaced modules. #304

Open
mcteo opened this issue Sep 1, 2020 · 4 comments
Open

ERR_STORE_NOT_PROVIDED when using named namespaced modules. #304

mcteo opened this issue Sep 1, 2020 · 4 comments

Comments

@mcteo
Copy link

mcteo commented Sep 1, 2020

Hi all,

I'm getting some weird behaviour when using "namespaced": true on my VuexModules.

I've reproduced the error in it's simplest form here: https://codesandbox.io/s/dreamy-hellman-th2fc

Essentially, I'm using the "namespace" helper from "vuex-class", and it is not able to find the VuexModule when it is given a name. A workaround for now is to not use the name, but I'd like some guidance, or documentation updates to see what is going wrong.

Thanks.

@mc6415
Copy link

mc6415 commented Nov 7, 2020

Not the guidance you wanted but another voice adding to this, after beating my head against a brick wall for the best part of this evening I came across this, removed the name and bam there it goes all working, would be good if like you said we could get some guidance, documentation or otherwise about this.

@AlexFilipovici
Copy link

... beating my head against a brick wall for the best part of this evening ...

Same here:

// @Module({ name: 'lists', store: store, dynamic: true, })
// @Module({ name: 'lists', store: store, dynamic: true, preserveState: true, namespaced: true })
// @Module({ name: 'lists', namespaced: true, store: store })
@Module({ namespaced: true }) // <= WORKS!

@StevenHX
Copy link

has the problem been solved?how to do?

@sebastianhaberey
Copy link

@Module({ namespaced: true }) // <= WORKS!

@AlexFilipovici if I leave out the name, I am getting ERR_GET_MODULE_NAME : Could not get module accessor. when accessing my modules in my Vue components via getModule(..). Did you not get this error?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants