codejump

Functional Guards

Preview — 3 of 10 questions

What does withComponentInputBinding() enable?

AIt allows components to bind to each other's @Input() properties directly
BIt makes @Input() properties available in route guards via injection
CIt enables two-way binding between router state and form controls
DIt automatically binds route parameters, query params, and resolver data to matching component @Input() properties

How do named router outlets work?

ANamed outlets are independent outlets (<router-outlet name="sidebar">) that are activated by routes with a matching outlet property, allowing multiple components to render simultaneously
BMultiple components render in the same outlet, stacked on top of each other
CNamed outlets are used exclusively for modal dialogs
DNamed outlets replace child routes and cannot be used together

How do you configure scroll restoration with Angular's router?

AAngular automatically scrolls to the top on every navigation — no configuration needed
BAdd scrollRestoration: 'auto' to the browser's History API manually
CUse withInMemoryScrolling() feature in provideRouter(), configuring scrollPositionRestoration and anchorScrolling
DUse @HostListener('scroll') in the root component to save and restore scroll position

Sign up free to play

Answer all 10 questions (7 more), see explanations for every answer, and track your score.