Managing State with ngrx

As you’ve just seen, handling state in an application can be tricky, especially when it comes time to optimize. In this section, you’ll learn about ngrx, a tool you can use to model all of your application state as a series of observable streams. The application’s state is centralized within ngrx, preventing rogue components from mistakenly modifying application state. This state centralization gives you precise control over how state can be modified by defining reducers. If you’ve ever used Redux, a lot of the same patterns apply.

Previously, applications would allow components to modify state without regard for the consequences. There was no concept of a “guard” in place to ensure that this centralized state could ...

Get Build Reactive Websites with RxJS now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.