Skip to content

Overview

This project provides a simple implementation of the state management pattern for angular applications.

Definition from AOE

State Management is a design pattern with the goal of properly sharing state data across components and separating domain representation from state management. This pattern is applied by many popular web frameworks such as Vuex, Redux or Flux.

Especially in reactive systems, this pattern helps to solve the task of maintaining decoupled, stateless components with immutable data. The ways of implementing state management differs and depends on the specific requirements of the application at hand.

There are already plenty solutions to do that (NgRx, NGXS, akita...). So why another implementation?

Maybe the answer is to provide a really simple implementation based on existing libraries and made for Angular application only, an implementation that does what we expect and not more.

The implementation is inspired from Redux.

Overview Overview

  • The registration of all the active objects is made by using the dependency injection of angular;
  • The update of the state uses immutability-helper;
  • The state notifications are based on RxJS.

To use this state management implementation, install the packages and add the following in your app.config.ts file:

provideNgssmStore()