Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
E

evenement

> 编程语言
Open source

Événement is a very simple event dispatching library for PHP.

1.4K stars0 likes1 views
WebsiteGitHub

About

Événement is a very simple event dispatching library for PHP.

Événement

Événement is a very simple event dispatching library for PHP.

It has the same design goals as Silex and Pimple, to empower the user while staying concise and simple.

It is very strongly inspired by the EventEmitter API found in node.js.

Fetch

The recommended way to install Événement is through composer. By running the following command:

bash
    $ composer require evenement/evenement

Usage

Creating an Emitter

php
<?php
$emitter = new Evenement\EventEmitter();

Adding Listeners

php
<?php
$emitter->on('user.created', static function (User $user) use ($logger): void {
    $logger->log(sprintf("User '%s' was created.", $user->getLogin()));
});

Removing Listeners

php
<?php
$emitter->removeListener('user.created', static function (User $user) use ($logger): void {
    $logger->log(sprintf("User '%s' was created.", $user->getLogin()));
});

Emitting Events

php
<?php
$emitter->emit('user.created', [$user]);

Tests

bash
    $ ./vendor/bin/phpunit

License

MIT, see LICENSE.

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

PHP

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言