From 74e26a60d41a8eb5638fdf6a0eccc5b4431e89fc Mon Sep 17 00:00:00 2001 From: Evgeny Fedorenko Date: Tue, 4 Feb 2020 21:05:02 -0500 Subject: [PATCH] feat(router): reverting some changes and applying suggestions Closes #2225 --- .../content/guide/router-store/configuration.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/projects/ngrx.io/content/guide/router-store/configuration.md b/projects/ngrx.io/content/guide/router-store/configuration.md index c356564fb7..b8fca2363e 100644 --- a/projects/ngrx.io/content/guide/router-store/configuration.md +++ b/projects/ngrx.io/content/guide/router-store/configuration.md @@ -21,7 +21,7 @@ interface StoreRouterConfig {
The `DefaultRouterStateSerializer` cannot be used when [serializability runtime checks](guide/store/configuration/runtime-checks) are enabled. -With runtime checks enabled `MinimalRouterStateSerializer` serializer is used by default in `RouterStoreModule` when no other serializer is provided. This also applies to Ivy with immutability runtime checks. +With serializability runtime checks enabled, the `MinimalRouterStateSerializer` serializer **must** be used. This also applies to Ivy with immutability runtime checks.
@@ -41,14 +41,14 @@ import { Params, RouterStateSnapshot } from '@angular/router'; import { RouterStateSerializer } from '@ngrx/router-store'; export interface RouterStateUrl { -url: string; -params: Params; -queryParams: Params; + url: string; + params: Params; + queryParams: Params; } export class CustomSerializer implements RouterStateSerializer<RouterStateUrl> { -serialize(routerState: RouterStateSnapshot): RouterStateUrl { -let route = routerState.root; + serialize(routerState: RouterStateSnapshot): RouterStateUrl { + let route = routerState.root; while (route.firstChild) { route = route.firstChild;