React Facades + RxJS

Thomas Burleson
8 min readJan 14, 2020

State Management

Applications often (a) need to share or reuse data and (b) have many events to change data. State management allows us to centralize data changes and control the insanity.

Developers often approach state management with reluctance, fear, and a naive understanding of when and how to use it.

I decided to write this tutorial to demonstrate real-world, best-practices when using state management in React.

State management is important when data:

  1. Must be shared between components,
  2. Must be accessible independent of view instances, and
  3. Changes to the data should be centralized
  4. Changes notifications should performantly update views

Redux Pattern

The Redux pattern is widely recognized as an important choice to manage state changes. Unfortunately, implementations of the Redux pattern (eg ReduxJS) often leads to lots of cruft (large numbers of files).

Let’s use a better solution (and avoid the cruft)!

Akita for State Management.

Akita is a relatively quiet newcomer — which uses the Flux/Redux patterns — that is making a huge splash in the RxJS + State Management

--

--

Thomas Burleson

Solutions architect expert in NextJS, React and Angular solutions. Formerly a Principal Architect @ Nrwl.io, Team Lead for Angular, Google.