News for hackers. Stuff that matters.
Re:Why React/Redux is inferior as a paradigm by moogleii on Wednesday January 20, 2016 @05:24PM (#10941853)
I might be misunderstanding you, but if you mean handling state at run-time, I feel like handling it in multiple places would be more complex, no? Otherwise, you can actually define state handlers (or as redux calls it, reducers) in multiple files as well, so that each subsection of state is being handled independently.
Re:Why React/Redux is inferior as a paradigm by EvanPlaice on Wednesday January 20, 2016 @09:48PM (#10943033)
Nope

NG2 services are essentially just singletons that can be injected into any component.

You can specify a server as an application wide provider (ie attach during bootstrap) or a component-specific provider.

Once a service is injected into a component all you have to do is set subscribe a variable to the service's observable. It the variable is bound to the view, it should update automatically. Event handling can be setup to update the observable by calling .next().

NG2 uses Rxjs (Reactive Extensions for JS) which is just the observable structures plus a ton of functional extensions (ie equivalent to reducers) that can add all sorts of inline transforms. Ex flatMap, filter, debounce, etc.

The Rxjs observable API is almost identical to promises. Except you call .subscribe() instead of .then() and the subscription can be disposed of at any time (ie promises always run to completion).

Rxjs uses hot and cold observables. For cold, subscriptions each have their own independent state and disposing of the subscription will stop the observer from retrieving further updates. Hot observables publish updates to all observers and keep updating even when there are no subscribers. Basically, cold observables are like 'on demand' viewing whereas hot is like watching a 'live stream'.

Re:Why React/Redux is inferior as a paradigm by stardrive on Thursday January 21, 2016 @02:24AM (#10943871)
Not sure if you've looked at Cycle Drivers, they are essentially services or plugins for side-effects. You manage them through sources and sinks and utilize them where every you like, as they run through dataflow components, very powerful and clean.

See http://cycle.js.org/drivers.html