We want to be able to trace where we are in the application—where—is represented by our route, route parameters, as well as by query parameters. By saving where we are, down to our store, we are able to easily serialize the stores information to a storage for later retrieval and deserialization, which means we can re-instate the app with not only the state, but also our page location.
@ngrx/router-store
Installation and set up
The router store is in an NPM package and we can therefore type the following to install it:
npm install @ngrx/router-store --save
The next thing we need to do is to import the correct modules and set those up in the import properties of our root module, like so:
import { BrowserModule...