Objective
I am attempting to add styles to the active route in a sidebar using css modules while still maintaining the base styles by assigning 2 classes.
This is the code I have tried:
<NavLink
to={path}
className={`
${classes.nav_link} ${({ isActive }) =>
isActive ? classes.active : classes.nav_link}
}
`}
>
However, it compiles to A snapshot of the css compiled code in devtools
I am utilizing CSS modules and React Router V6