This package is abandoned and no longer maintained. No replacement package was suggested.

Blade helpers and tools

1.0.2 2019-09-06 00:27 UTC

This package is auto-updated.

Last update: 2020-11-05 23:01:08 UTC


README

ARCHIVED: This project is archived and no longer maintained.

This adds useful blade tools.

Installation

composer require package-for-laravel/blade

Usage

@activeroute directive

This takes a route string or array and returns the word active if that pattern is matched. It's proxied to Request::Is

<a href="{{ route('users.index') }}" class="menu-link @activeroute(['users.*'])">Users</a>

This would make a class of menu-link active when you are on routes named users.index or users.create, but just menu-link on companies.index.

Credits

This package is created and maintained by Aaron Saray