| Route | R Documentation |
https://api.reactrouter.com/v7/functions/react-router.Route.html
Route(
...,
element,
loader = NULL,
action = NULL,
errorElement = NULL,
key = randomKey()
)
... |
Additional Route props (see Details). |
element |
The element to render when the route matches. Wrapped on
the JS side in a no-DOM |
loader |
Optional. A |
action |
Optional. A |
errorElement |
Optional. Element rendered when the route's
|
key |
Stable React key for the route's |
Internally the 'element' is wrapped in a 'shiny::div()' with a UUID key so, in case R shiny is used, shiny can differentiate each element.
Additional React Router Route props can be passed through ...:
path (Character): path pattern, supports :param,
optional :param?, and splat *.
index (Boolean): mark this as the index route of its parent.
caseSensitive (Boolean): match the path case-sensitively.
id (Character): stable route id, required for use with
useRouteLoaderData.
handle (Any): arbitrary value exposed via
useMatches for breadcrumbs and similar use cases.
shouldRevalidate (JS): function controlling
whether the loader re-runs on a given navigation.
lazy (JS): code-splitting hook returning a
Promise resolving to a route module.
hasErrorBoundary (Boolean): explicit error-boundary flag
(rarely needed when errorElement is provided).
A Route component.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.