MCPcopy Create free account
hub / github.com/getsentry/sentry-javascript / withSentryRouterRouting

Function withSentryRouterRouting

packages/solid/src/solidrouter.ts:162–172  ·  view source on GitHub ↗
(Router: RouterType)

Source from the content-addressed store, hash-verified

160 * A higher-order component to instrument Solid Router to create navigation spans.
161 */
162export function withSentryRouterRouting(Router: RouterType): RouterType {
163 const SentryRouter = (props: Parameters<RouterType>[0]): JSX.Element => {
164 const [local, others] = splitProps(props, ['root']);
165 // We need to wrap root here in case the user passed in their own root
166 const Root = withSentryRouterRoot(local.root ? local.root : SentryDefaultRoot);
167
168 return createComponent(Router, mergeProps({ root: Root }, others));
169 };
170
171 return SentryRouter;
172}

Callers 5

app.tsxFile · 0.90
app.tsxFile · 0.90
app.tsxFile · 0.90
app.tsxFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected