MCPcopy Create free account
hub / github.com/angular/angular / withComponentInputBinding

Function withComponentInputBinding

packages/router/src/provide_router.ts:856–868  ·  view source on GitHub ↗
(
  options: ComponentInputBindingOptions = {},
)

Source from the content-addressed store, hash-verified

854 * @returns A set of providers for use with `provideRouter`.
855 */
856export function withComponentInputBinding(
857 options: ComponentInputBindingOptions = {},
858): ComponentInputBindingFeature {
859 const providers = [
860 {
861 provide: INPUT_BINDER,
862 useFactory: () =>
863 new RoutedComponentInputBinder(options, inject(ROUTER_RESOURCES_FEATURE, {optional: true})),
864 },
865 ];
866
867 return routerFeature(RouterFeatureKind.ComponentInputBindingFeature, providers);
868}
869
870/**
871 * Enables view transitions in the Router by running the route activation and deactivation inside of

Calls 2

injectFunction · 0.90
routerFeatureFunction · 0.85

Tested by

no test coverage detected