yzen.dev / laravel-local-mailer
Installs: 2 452
Dependents: 0
Suggesters: 0
Security: 0
Stars: 37
Watchers: 2
Forks: 2
Open Issues: 1
Requires
- php: ^7.4 | ^8.0
- laravel/framework: ^7.0|^8.0|^v9.0
Requires (Dev)
- mockery/mockery: 1.*
- orchestra/testbench: 6.*|7.*|8.*
- phpstan/phpstan: ^0.12.37
- phpunit/phpunit: 9.5.20
- squizlabs/php_codesniffer: *
This package is auto-updated.
Last update: 2024-11-06 17:58:26 UTC
README
Each developer needs to check the sending of email messages during development. Most of them have their own ways - usage gmail, Mailtrap, laravel logs, etc.
This solution will create its own mail transport, saving emails as daily logs, with the ability to view!
📜 Installation
The package can be installed via composer:
composer require yzen.dev/laravel-local-mailer
In the config config/mail.php add a new transport:
return [ //... 'mailers' => [ //... 'local-mailer' => [ 'transport' => 'local-mailer' ], ] ]
Now you can include this transport in the env:
MAIL_MAILER=local-mailer
The page for viewing is available at {HOST}/local-mailer
.
Here you can view the log for any date. For each log, the full email will be displayed - the title, to, contents of the letter (html page), attached files, etc.