New

Just launched: Vueblocks, a brand-new search engine for Vue packages! Explore Vueblocks →

envant/fireable

An elegant way to trigger events based on attributes changes
805,847 442

Larablocks Analysis

envant/fireable works with Laravel 5 to 10 (latest release v1.0.11, Mar 8, 2023), all past end of life (the last on Feb 4, 2025): no more fixes, even for security.

Recommendation checks

Not advised

Not advised: no release or commit in over 2 years.

  • No release or commit in over 2 years
  • Supports only Laravel 5 to 10, past end of life since Feb 4, 2025
  • No release in the last 12 months (last: Mar 8, 2023)
  • 1,318 downloads a month (needs 10,000)
  • 442 GitHub stars (at least 100)

State

Likely abandoned
  • No release or commit in over 2 years.
  • Last stable release: Mar 8, 2023.
  • No releases in the last 12 months.
  • First released: Sep 19, 2019.
  • Monthly downloads: 1,318, up 21% from six months ago.
  • 3 open issues on GitHub.

Data from Packagist and GitHub, checked by Larablocks on Dec 1, 2026.

Install
composer require envant/fireable
Latest Version:v1.0.11
PHP:^7.2|^8
Laravel:5 – 10
License:MIT
Last Updated:Mar 1, 2024
Links: GitHub  ·  Packagist
Maintainer: lepikhinb

Fireable

Latest Version on Packagist StyleCI Build Status Total Downloads

An elegant way to trigger events based on attributes changes.

Installation

Install package through Composer

$ composer require envant/fireable

Usage

  1. Add the FireableAttributes trait to your model
  2. Define the attributes with specified events via the protected $fireableAttributes property on the model

Example

Let's say we need to trigger specified events when specific model attributes are updated.

For example, you need to notify user when he gets an "approved" status. Instead of observing model's "dirty" attributes and firing events manually we could do it more elegantly by assigning specified events to attributes or even certain values of attributes.

class User extends Authenticatable
{
    use FireableAttributes;

    protected $fireableAttributes = [
        'status' => [
            'approved' => UserApproved::class,
            'rejected' => UserRejected::class,
        ],
    ];
}

Also you may not need to track certain values, so you can assign an event directly to an attribute itself. So, in the example below, each time the user's email is changed, the appropriate event will be fired.

class User extends Authenticatable
{
    use FireableAttributes;

    protected $fireableAttributes = [
        'email' => EmailUpdated::class,
    ];
}

Change log

Please see the changelog for more information on what has changed recently.

Testing

$ composer test

Contributing

Please see contributing.md for details and a todolist.

Security

If you discover any security related issues, please email author email instead of using the issue tracker.

Credits

License

license. Please see the license file for more information.

Related Packages

deferdie/event

Event management for Laravel 5

16 0
humweb/event

This package helps to create event dispatcher services

46 0
technote/laravel-transaction-fire-event

Controlling events that occur in a transaction

11,584 1
desmart/laravel-event-sourcing

Laravel bindings for DeSmart Event Sourcing package

37 7
sebdesign/laravel-state-machine

Winzou State Machine service provider for Laravel

1,531,599 341

Version History

Version Released PHP Laravel License
v1.0.11 ^7.2|^8 ^5.8|^6|^7|^8|^9|^10.0 MIT
v1.0.10 ^7.2|^8 ^5.8|^6|^7|^8|^9 MIT
1.0.9 ^7.2|^8 ^5.8|^6|^7|^8 MIT
1.0.8 ^7.2 ^5.8|^6|^7|^8 MIT
v1.0.7 ^7.2 ^5.8|^6|^7 MIT