davestewart/vue-class-store

Practical examples with async

Opened this issue · 2 comments

Hi Dave!
First I would like to Thank You on the great work with vuex-pathify!
Vue-class-store is an interesting take! Would love to see practical examples with async data fetching if that is a scope you agree.

Keep up the good work!

Hey!

Thanks for the kind words and your interest in this project!

Yes, I plan to flesh out the examples and stress-test the idea a bit more.

You should be able to do something with async data right now; just set up a method and populate the model itself.

The main thing I've been thinking for a long time about the idea of "universal stores" and want to see if I can create:

  • a global store harness
  • a flux harness / wrapper / decorator

That way it's just one format for stand-alone, component, global or flux stores.

Please comment if you have thoughts!

The way I see it you just did that with vue-class-store, the provide-inject usage is great, the flux pattern I'm not even sure is needed here, but who knows? I see that I can do async, you didn't tied the hands of the user to anything and it is a great thing! Thinking about usages with vue-rx and/or xstate. I'll play with it and come back to you if I do have usable thoughts!