Open mcoetzee opened 8 years ago
I liked your article and I think it's great you want to contribute what you've been working on to the OSS community! Keep it up!
FWIW: My team at Netflix has been using RxJS in tandem with Redux via https://github.com/redux-observable/redux-observable. There are a few reasons for this, but mostly it's so we can have all of the nice tooling and community support that Redux provides. While it's true that Redux's store can be implemented in a few lines of RxJS, it's also true that the rest of the Redux ecosystem cannot be implemented in a few lines of RxJS. Also, it doesn't really matter if the reduction occurs in Redux or RxJS scan, as long as it occurs. :)
I think your article is great and I love what you're working on here, keep it up!
Also worth noting, Redux stores can be made into a stream of state like so now: Observable.from(store)
. ;)
Thanks @blesh - I really appreciate the feedback.
Yeah I took a look at the work you and Jay Phelps did with redux-observable. Really cool stuff. It looks like it was well received by the community.
I definitely get where you are coming from - the Redux ecosystem is pretty impressive. The one thing that I can’t seem to shake off though, is the point I raised in the article about the amount of no-ops in Redux… Maybe it’ll only be an issue on a mobile device with a large amount of connected components ¯(ツ)/¯
At the very least this exercise has given me a decent introduction to RxJS, but I think some more experimentation is in order in this space :) Thanks for the motivation.
P.S. I thought it was about time that I pushed some code up to NPM :)
Just stumbled on your article and I find it very interesting. I'm also trying to come to a simple setup relying exclusively on RxJS. I've been struggling with async stuff though, when you want to know that stuff is being loaded or when you need a specific ID from your state. You nailed those 2 points down in a nice way! Keep up the good work and I'm looking forward to read about your "slightly different approach" :)
Cheers.
Yeah to give a quick update - the different approach I experimented with was around using action streams with Redux: https://github.com/mcoetzee/redux-stream
I was reasonably happy with it but then saw that redux-observable deprecated their old approach and made action streams their main thing. Action streams is really the bread and butter of what I talked about in the article, so I'm super happy with redux-observable. We've been using it in production for about a month and it's great. I'm planning to write about it at some point.
So long story short - I would recommend going the redux-observable route.
Awesome, @mcoetzee. I'm glad it's been beneficial!
Ok, thanks for the update, that's very helpful. I'll go check redux-observable
then.
@qur2 I'm glad I could help.
@blesh Yeah our action streams are flowing like a dream! Thanks for all the hard work over there
I was originally in search of a RxJS Redux replacement and ended up writing an observable version of react-redux connect instead. Would love feedback! Code: https://github.com/cif/redux-fusion Process: https://medium.com/@benipsen/introducing-redux-fusion-an-alternative-approach-to-react-reduxs-connect-method-for-rxjs-44248895b47d
I have made the case for using RxJS for unidirectional data flow over here: https://medium.com/@markusctz/state-streams-and-react-7921e3c376a4
Any critique on the article or this library (especially its API) would be more than welcome. Being relatively new to reactive programming I'm aware that I might be overlooking something.
I promise no feelings will be hurt.