Feature request: NavLink (Like in react-router-dom)

This issue has been tracked since 2021-12-13.

I would like to request that you build in a feature like the NavLink from react-router-dom. There you can set an activeClassName that will be used when the URL is equal to the path of the NavLink. This means you don't have to check and calculate which route you are on when refreshing the window and then afterwards set the active class.

EmilTholin wrote this answer on 2021-12-14

Hi @WhereCanI!

The documentation of Link describes the property getProps and how you can use it to build your own NavLink.

More Details About Repo
Owner Name EmilTholin
Repo Name svelte-routing
Full Name EmilTholin/svelte-routing
Language JavaScript
Created Date 2017-11-28
Updated Date 2022-12-03
Star Count 1711
Watcher Count 21
Fork Count 151
Issue Count 59


Issue Title Created Date Updated Date