PHPackages                             reedware/laravel-events - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. reedware/laravel-events

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

reedware/laravel-events
=======================

Define all of your events in a simple configuration file.

v1.0.2(4y ago)471MITPHPPHP ^7.1.3|^8.0

Since Apr 29Pushed 4y ago1 watchersCompare

[ Source](https://github.com/tylernathanreed/laravel-events)[ Packagist](https://packagist.org/packages/reedware/laravel-events)[ RSS](/packages/reedware-laravel-events/feed)WikiDiscussions master Synced today

READMEChangelog (3)Dependencies (3)Versions (4)Used By (0)

Laravel Events
==============

[](#laravel-events)

[![Latest Stable Version](https://camo.githubusercontent.com/0ef20198b057d8c08e0e2a2939b6fe21d16587d5ac7d7d93a26f92bec6c0e8e6/68747470733a2f2f706f7365722e707567782e6f72672f72656564776172652f6c61726176656c2d6576656e74732f762f737461626c65)](https://packagist.org/packages/reedware/laravel-events)[![Laravel Version](https://camo.githubusercontent.com/14753566f1c75119a745f0e877b105dde3a4bf7713d3fa1117adc1729c89422b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2d362e782d2d382e782d626c7565)](https://laravel.com/)[![Build Status](https://github.com/tylernathanreed/laravel-events/workflows/tests/badge.svg)](https://github.com/tylernathanreed/laravel-events/actions)

This package allows you to define all of your events in a simple configuration file.

Introduction
------------

[](#introduction)

Events in Laravel are a fantastic tool to use. However, once you start leaning into events heavily, managing everything through the service provider can be a bit cumbersome. While [event discovery](https://laravel.com/docs/5.8/events#event-discovery) exists (since Laravel 5.8), this doesn't always solve the entire problem. This package will allow you to define listeners, subscribers, and observers within a configuration file. Additionally, the implementation allows you to be a bit more lackadaisical with registration, with no performance cost after caching events.

Installation
------------

[](#installation)

### Composer

[](#composer)

First, start by installing this package.

```
composer require reedware/laravel-events

```

### Configuration

[](#configuration)

Next, you'll need to get your hands on the `events.php` configuration file. You can either copy it directly, or publish it.

```
php artisan vendor:publish

```

### Service Provider

[](#service-provider)

Finally, you'll need to modify your service provider. You can either extend the example provider in the package, or you can utilize the trait.

#### Extending the Service Provider

[](#extending-the-service-provider)

```
