What is router outlet?

Technology CommunityCategory: AngularWhat is router outlet?
VietMX Staff asked 3 years ago

The RouterOutlet is a directive from the router library and it acts as a placeholder that marks the spot in the template where the router should display the components for that outlet. Router outlet is used as a component,

    <router-outlet></router-outlet>
    <!-- Routed components go here -->