href

href

Summary

Reference Documentation ↗

Returns a resolved URL path for the specified route.

const h = href("/:lang?/about", { lang: "en" })
// -> `/en/about`

<Link to={href("/products/:id", { id: "abc123" })} />
Docs and examples CC 4.0