PHP code example of onefit / events
1. Go to this page and download the library: Download onefit/events library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
onefit / events example snippets
return [
'producers' => [
\MyModels\Member::class => [
'member' => 'member_domain',
],
],
'listeners' => [
'notifications' => 'member_domain',
],
'source' => 'my-awesome-app',
];
event('notifications.user_paid', $myUserInstance);