PHPackages                             patryknamyslak/patflow - 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. patryknamyslak/patflow

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

patryknamyslak/patflow
======================

An event driven dispatch system for php

v1.2(2mo ago)06MITPHP

Since Feb 10Pushed 2mo agoCompare

[ Source](https://github.com/PatrykNamyslak/PatFlow)[ Packagist](https://packagist.org/packages/patryknamyslak/patflow)[ RSS](/packages/patryknamyslak-patflow/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)DependenciesVersions (4)Used By (0)

PatFlow - Event Dispatching System
==================================

[](#patflow---event-dispatching-system)

Demo:
-----

[](#demo)

### TestEvent:

[](#testevent)

```
namespace PatrykNamyslak\PatFlow\Demo;

use PatrykNamyslak\PatFlow\Blueprints\Event;

class TestEvent extends Event{
    // Add a custom property to capture extra data to then later use in the Listener::handle() method
    public function __construct(protected string $message){
        parent::__construct();
    }
}
```

### TestListener:

[](#testlistener)

```
namespace PatrykNamyslak\PatFlow\Demo;

use PatrykNamyslak\PatFlow\Blueprints\Event;
use PatrykNamyslak\PatFlow\Blueprints\Listener;

class TestListener extends Listener{
    public function handle(Event $event): void{
        echo "Event triggered! at: {$event->timestamp} and a message was left here it is: {$event->message}";
    }
}
```

### TestServiceProvider:

[](#testserviceprovider)

```
namespace PatrykNamyslak\PatFlow\Demo;

use PatrykNamyslak\PatFlow\Blueprints\ServiceProvider;

class TestServiceProvider extends ServiceProvider{
    // Define your event => array of listeners that are triggered on event fire
    public array $listen = [
        TestEvent::class => [TestListener::class],
    ];
}
```

Usage:
------

[](#usage)

```
use PatrykNamyslak\PatFlow\Demo\TestEvent;
use PatrykNamyslak\PatFlow\Demo\TestServiceProvider;

$dispatcher = new Dispatcher();

$serviceProvider = new TestServiceProvider(dispatcher: $dispatcher);
$serviceProvider->register();
$dispatcher->dispatch(new TestEvent(message: "Greetings My friend"));
```

```
OUTPUT: Event triggered! at: 1770753871.8842 and a message was left here it is: Greetings My friend

```

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance85

Actively maintained with recent releases

Popularity4

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~10 days

Total

3

Last Release

77d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/65c81cbbb028fa73196ab7a01c410588bc79f2f09350597f58d65f8c5801099f?d=identicon)[PatrykNamyslak](/maintainers/PatrykNamyslak)

---

Top Contributors

[![PatrykNamyslak](https://avatars.githubusercontent.com/u/143219631?v=4)](https://github.com/PatrykNamyslak "PatrykNamyslak (11 commits)")

### Embed Badge

![Health badge](/badges/patryknamyslak-patflow/health.svg)

```
[![Health](https://phpackages.com/badges/patryknamyslak-patflow/health.svg)](https://phpackages.com/packages/patryknamyslak-patflow)
```

###  Alternatives

[pxlrbt/filament-environment-indicator

Indicator for the current environment inside Filament

151923.9k12](/packages/pxlrbt-filament-environment-indicator)[simplito/bn-php

Big number implementation compatible with bn.js

202.2M15](/packages/simplito-bn-php)[typo3/cms-t3editor

TYPO3 CMS T3Editor - JavaScript-driven editor with syntax highlighting and code completion. Based on CodeMirror.

115.9M50](/packages/typo3-cms-t3editor)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
