Package-level declarations
Types
The interface for the navigate() function returned from useNavigate().
Properties
Component to use for rendering lazily loaded data from returning defer() in a loader function
Changes the current location.
Renders the child route's element, if there is one.
Given a Remix Router instance, render the appropriate UI
Functions
Renders the result of matchRoutes()
into a React element.
Returns the action data for the nearest ancestor Route action
Returns the error from the nearest ancestor <Await />
value
Returns the happy-path data from the nearest ancestor <Await />
value
Allow the application to block navigations within the SPA and present the user a confirmation dialog to confirm the navigation. Mostly used to avoid using half-filled form data. This does not handle hard-reloads or cross-origin navigations.
Returns the full href for the given "to" value. This is useful for building custom links that are also accessible and preserve right-click behavior.
Returns true if this component is a descendant of a <Router>
.
Returns the loader data for the nearest ancestor Route loader
Returns the current location object, which represents the current URL in web browsers.
Returns the active route matches, useful for accessing loaderData for parent/child routes or the route "handle" property
Returns an imperative method for changing the location. Used by <Link>
s, but may also be used by other elements to change the location.
Returns the current navigation, defaulting to an "idle" navigation when no navigation is in progress
Returns the current navigation action which describes how the router came to the current location, either by a pop, push, or replace on the history stack.
Returns the element for the child route at this level of the route hierarchy. Used internally by <Outlet>
to render child routes.
Returns the context (if provided) for the child route at this level of the route hierarchy.
Resolves the pathname of the given to
value against the current location.
Returns a revalidate function for manually triggering revalidation, as well as the current state of any manual revalidations
Returns the nearest ancestor Route error, which could be a loader/action error or a render error. This is intended to be called from your ErrorBoundary/errorElement to display a proper error message.
Returns the ID for the nearest contextual route
Returns the loaderData for the given routeId
Returns the element of the route that matched the current location, prepared with the correct context to render the remainder of the route tree. Route elements in the tree must render an <Outlet>
to render their child route's element.