在一个地方查看您 laravel 应用中的所有可发送的邮件
The Design and content team members often need access to the emails your app will be sending out to the users. This is a fairly simple package that makes it possible and tries to minimize developer dependency. By using this package, you can have a dedicated route to view all your mailables at a single place. Having shareable URLs to view the mails makes the team co-ordination more smooth.
You can install this package via composer using this command:
composer require joggapp/laravel-mail-viewerThe package will automatically register itself.
You will have to add the mailables and configure the other settings using the package's config file in order to to use this package. Please read the comments/description for each config key thoroughly and set their values. You can publish the config file with:
php artisan vendor:publish --provider="JoggApp\MailViewer\MailViewerServiceProvider"This will create the package's config file called mailviewer.php in the config directory. These are the contents of the published config file:
…After setting up the config values as described above, you can see the list of all mailables by visiting the /mails route (considering the default url is 'mails' in the config file). You can modify it to whatever you want as per your needs.
You can also restrict the environments the package should list the mailables in. By default, the allowed_environments config is set to allow 3 environments: local, staging & testing. You can further secure it using the middlewares config.
Default view:
| List of all mails | A particular mail rendered |
|---|---|
You can run the tests with:
vendor/bin/phpunitPlease see CHANGELOG for more information what has changed recently.
If you discover any security related issues, please email [email protected] instead of using the issue tracker.
The MIT License (MIT). Please see License File for more information.
暂无开放 Issues,或尚未同步最近议题。