mercredi 3 octobre 2018

Apply "active" class on active url in Laravel dynamically, what is the clean and reusable way?

For the following URLs:

I want to apply class "active" to users navigation dynamically in Laravel as follows:

<ul>
    <li class="active"><a href="">Users</a></li>
    <li class=""><a href="">Pages</a></li>
</ul>

What is the clean and reusable way to do this without using third party plugins?



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire