extractDynamicRouteParams() works but:
- Transaction names are noisy/uninformative (
index, (tabs)).
- Dynamic param extraction almost never finds matching keys, so spans rarely carry
route.params.* attributes.
useFullPathsForNavigationRoutes builds a path from nested navigators, but it joins React Navigation names, not Expo Router pathnames.
Here is what we can do: When Expo Router is active, derive the route from Expo Router's own state rather than from getCurrentRoute().name:
- Use the Expo Router path (e.g.
/profile/[id]) as the canonical span name and route.name attribute.
- Extract dynamic params from the matched route pattern + the actual
params object, including catch-all [...slug].
- Keep query-string params off the span by default; gate them behind
sendDefaultPii (matching the existing PII model in deeplink.ts and the current extractDynamicRouteParams contract).
- Set
route.path (templated) and, under sendDefaultPii, route.url (concrete).
extractDynamicRouteParams()works but:index,(tabs)).route.params.*attributes.useFullPathsForNavigationRoutesbuilds a path from nested navigators, but it joins React Navigation names, not Expo Router pathnames.Here is what we can do: When Expo Router is active, derive the route from Expo Router's own state rather than from
getCurrentRoute().name:/profile/[id]) as the canonical span name androute.nameattribute.paramsobject, including catch-all[...slug].sendDefaultPii(matching the existing PII model indeeplink.tsand the currentextractDynamicRouteParamscontract).route.path(templated) and, undersendDefaultPii,route.url(concrete).