main
Branches
main (6.22.3)dev
Versions
6.22.3v4/5.xv3.x
useMatch

useMatch

Type declaration
declare function useMatch<
  ParamKey extends ParamParseKey<Path>,
  Path extends string
>(
  pattern: PathPattern<Path> | Path
): PathMatch<ParamKey> | null;

Returns match data about a route at the given path relative to the current location.

See matchPath for more information.

Docs and examples CC 4.0
Edit