router
router copied to clipboard
Prevent using an unregistered custom element for a route Component
If you happen to define your routes with a component
that hasn't been added to the custom element registry (perhaps due to a missing import
), you will end up with a route that fails with no immediately obvious reason. Router could either warn or fail in this scenario. This should not prevent you from lazy-loading routes, as you use the action
property (instead of component
) to define a function for dynamically loaded routes.