Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/leavesster/vercel-router


https://github.com/leavesster/vercel-router

Last synced: 2 days ago
JSON representation

Awesome Lists containing this project

README

        

---
title: Custom Active Link
toc: false
---

# Custom Link Example

This example demonstrates how to make a custom `` component to render something different when the link is "active" using the `useMatch()` and `useResolvedPath()` hooks.

## Preview

Open this example on [StackBlitz](https://stackblitz.com):

[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/remix-run/react-router/tree/main/examples/custom-link?file=src/App.tsx)