Skip to main content
Renders the matching child route of a parent route or nothing if no child route matches.

Type Declaration

Props

unknown
Provides a context value to the element tree below the outlet. Use when the parent route needs to provide values to child routes.
Access the context with useOutletContext:

Examples

Basic Layout

Passing Context

Nested Outlets

Conditional Outlet

Behavior

  • Returns null if there is no child route that matches
  • Renders the element of the child route that matches the current location
  • Can be used multiple times in nested route hierarchies
  • Context is type-safe when used with TypeScript and proper typing