-
Notifications
You must be signed in to change notification settings - Fork 41
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
vuex and vue-worker #12
Comments
I'd like to know this too, please. |
I would like to know simply how to call a worker from a VueX action. Can somebody provide some guidance? |
This is likely not possible (or not feasible), because Web Workers don't share any data with the main thread. By design, communication between workers is done by passing messages, and such data is copied but never "shared". While technically it could be possible to set up a bunch of messages so that a worker could ask for data from the main thread, this is likely going to increase the overhead and the complexity of the code, and making it much slower to run and harder to maintain. |
Not true. Currently indexedb is blocking - and if you want to sync the store with your indexedb instance without freezing the DOM - using workers is the only way to make it truly non blocking. And yes, it is possible. The app will be faster. However I do not know if the module allows it, I have used worker-loader module before. |
Is it possible to access the vuex store from within a function passed onto a worker ?
The text was updated successfully, but these errors were encountered: