allParams Property Readonly

A signal state that includes the route params and query params

API

readonly allParams: SignalStateType<Q & P>;

Example

import {routeGroup} from '@bitfiber/ng/rx';
 
// Provides a group of signal states for managing the route
const route = routeGroup<{page: number; search: string}, {id: number; type: string}>({
  initialParams: {id: 0, type: 'all'},
  initialQueryParams: {search: '', page: 1},
}, ({allParams}) => {
  allParams
    // Performs a tap callback each time either the route params or query params change
    .tap(data => console.log(data));
});