Skip to content

Commit 7febcb5

Browse files
committed
refactor: remove TODO and notes
1 parent 61e229c commit 7febcb5

File tree

1 file changed

+0
-34
lines changed

1 file changed

+0
-34
lines changed

packages/router-component-store/src/lib/router-history-store/router-history.store.ts

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -34,40 +34,6 @@ export function provideRouterHistoryStore(): Provider[] {
3434
];
3535
}
3636

37-
// TODO(@LayZeeDK): Handle `NavigationCancel` and `NavigationError` events
38-
// NavigationStart -> NavigationEnd | NavigationCancel | NavigationError
39-
// NavigationSkipped -> (end)
40-
//
41-
// NavigationError resets the URL to what it was before the navigation that caused an error. No new *navigation* is triggered.
42-
// NavigationError reasons:
43-
// - Invalid route path
44-
// NavigationError(id: 3, url: '/an-invalid/path', error: Error: Cannot match any routes. URL Segment: 'an-invalid/path')
45-
// - Router resolver throws
46-
// - Route matcher throws
47-
// - Routed component throws in constructor (or a lifecycle hook?)
48-
// - Lazy route chunk file is not found (bundles updated and the user needs to refresh)
49-
// RouterTestingModule.withRoutes([
50-
// {
51-
// path: 'stale-chunk',
52-
// loadChildren: () =>
53-
// Promise.reject({ name: 'ChunkLoadError', message: 'ChunkLoadError' }),
54-
// // or () => { throw { name: 'ChunkLoadError', message: 'ChunkLoadError' }; }
55-
// },
56-
// ]),
57-
//
58-
// What is the URL after each of the following reasons?
59-
// NavigationCancel reasons:
60-
// NavigationCancel#code: NavigationCancellationCode
61-
// - GuardRejected: A navigation failed because a guard returned `false`.
62-
// - NoDataFromResolver: A navigation failed because one of the resolvers completed without emiting a value.
63-
// - Redirect: A navigation failed because a guard returned a `UrlTree` to redirect.
64-
// - SupersededByNewNavigation: A navigation failed because a more recent navigation started.
65-
// NavigationCancel { id: 3, url: "/company", reason: "Navigation ID 3 is not equal to the current navigation id 4" }
66-
//
67-
// NavigationSkipped reasons:
68-
// - `location` change to unsupported URL. The `UrlHandlingStrategy` cannot process the current or the target URL.
69-
// - `onSameUrlNavigation` is set to `ignore` (the default) and the target URL is the same as the current URL.
70-
7137
@Injectable()
7238
export class RouterHistoryStore extends ComponentStore<RouterHistoryState> {
7339
#router = inject(Router);

0 commit comments

Comments
 (0)