genealabs/laravel-authorization-addons

Additional helper methods and blade directives to help with more complex authorization queries.
689 6
Install
composer require genealabs/laravel-authorization-addons
Latest Version:13.0.0
PHP:^8.2
License:MIT
Last Updated:Mar 30, 2026
Links: GitHub  ·  Packagist
Maintainer: mikebronner

Authorization Addons for Laravel

Authorization Addons for Laravel masthead image.

Join the chat at https://gitter.im/GeneaLabs/laravel-authorization-addons Travis SensioLabs Insight Scrutinizer Coveralls GitHub (pre-)release Packagist GitHub license

Additional helper methods and blade directives to help with more complex authorization queries.

Usage

@canAny (iterable $abilities, $model)

Checks if any one of the abilities is authorized for the given model.

@canAny (['create', 'edit'], $post)

@canEvery (iterable $abilities, string $model)

Checks if all of the abilities are authorized for the given model.

@canEvery (['create', 'edit', 'remove'], $post)

@elseCanAny (iterable $abilities, string $model)

Same as @canAny, but allowing for multiple conditionals when checking authorizations.

@elseCanEvery (iterable $abilities, string $model)

Same as @canEvery, but allowing for multiple conditionals when checking authorizations.

Inverse Methods:

The following inverse methods are also available, along with the same signatures as their counterparts:

  • @cannotAny
  • @cannotEvery
  • @elseCannotAny
  • @elseCannotEvery

Related Packages

doctrine/dbal

Powerful PHP database abstraction layer (DBAL) with many features for database s...

641,106,524 9,700
laravel/framework

The Laravel Framework.

589,172,971 34,950
laravel/tinker

Powerful REPL for the Laravel framework.

498,216,183 7,442
laravel/serializable-closure

Laravel Serializable Closure provides an easy and secure way to serialize closur...

413,412,504 609
nunomaduro/collision

Cli error handling for console/command-line PHP applications.

394,964,158 4,660

Version History

Version Released PHP Laravel License
13.0.0 ^8.2 ^11.0|^12.0|^13.0 MIT
1.0.1 >=7.2 ^5.5|^6.0 MIT
1.0.0 >=7.2 5.5 - 6.0 MIT
0.2.0 >=7.1.3 5.5 - 5.8 MIT
0.1.4 >=7.0.0 5.5 - 5.7 MIT