Created
August 9, 2018 08:30
-
-
Save ahsankhatri/c7ddd9927e400d113f19516b85892be3 to your computer and use it in GitHub Desktop.
Preview Mailable in Browser Laravel 5.4
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Route::get('/preview-mail', function () { | |
$mail = (new \App\Mail\ShareItenraryTripStarted())->build(); | |
$mocked = new \ReflectionMethod($mail, 'buildView'); | |
$mocked->setAccessible(true); | |
return $mocked->invoke($mail)['html']; | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment