main
Branches
main (2.15.2)dev
Versions
2.15.21.19.3v0.21.0
React Router v7 has been released. View the docs
Outlet

<Outlet>

Renders the matching child route of a parent route.

import { Outlet } from "@remix-run/react";

export default function SomeParent() {
  return (
    <div>
      <h1>Parent Content</h1>

      <Outlet />
    </div>
  );
}

Props

context

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

<Outlet context={myContextValue} />

See also: useOutletContext

Docs and examples licensed under MIT