PHP code example of oltrematica / laravel-pulse-mail

1. Go to this page and download the library: Download oltrematica/laravel-pulse-mail 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/ */

    

oltrematica / laravel-pulse-mail example snippets


'recorders' => [
    // ... other recorders

    \Oltrematica\Pulse\Mail\Recorders\MailSentRecorder::class => [
        'enabled' => env('PULSE_MAIL_ENABLED', true),
    ],
],

return [
    // Maximum number of emails to display in the widget
    'limit' => env('PULSE_MAIL_LIMIT', 10),

    // Email addresses to exclude from tracking
    'ignore' => [
        'to' => [
            // '[email protected]',
        ],
    ],

    // Mailable classes to exclude from tracking
    'ignore_mailables' => [
        // \App\Mail\TestEmail::class,
    ],

    // Sample rate (0-1): 1 = track all emails, 0.5 = track 50%
    'sample_rate' => env('PULSE_MAIL_SAMPLE_RATE', 1),
];

// Ignore by recipient
'ignore' => [
    'to' => [
        '[email protected]',
        '[email protected]',
    ],
],

// Ignore by Mailable class
'ignore_mailables' => [
    \App\Mail\TestEmail::class,
    \App\Mail\InternalNotification::class,
],

// Track 50% of emails
'sample_rate' => 0.5,

// Or use environment variable
'sample_rate' => env('PULSE_MAIL_SAMPLE_RATE', 1),
bash
php artisan vendor:publish --tag=pulse-mail-config
bash
php artisan vendor:publish --tag=pulse-dashboard
bash
php artisan pulse:check
bash
php artisan pulse:work
json
"dev": [
    "npx concurrently \"php artisan serve\" \"php artisan queue:listen\" \"php artisan pulse:work\" \"npm run dev\""
]
shell
composer analyse