From c676d8ed5e7d7c5c96a509b08cfaafd633893100 Mon Sep 17 00:00:00 2001 From: braxey Date: Sat, 8 Nov 2025 17:06:55 -0500 Subject: [PATCH] feat: add dd() to Mailable --- src/Illuminate/Mail/Mailable.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/Illuminate/Mail/Mailable.php b/src/Illuminate/Mail/Mailable.php index 7e47f06a030d..c92e497c675d 100644 --- a/src/Illuminate/Mail/Mailable.php +++ b/src/Illuminate/Mail/Mailable.php @@ -294,6 +294,18 @@ public function render() }); } + /** + * Render the mailable into a view and display it, then halt execution. + * + * @throws \ReflectionException + */ + public function dd() + { + header('Content-Type: text/html; charset=UTF-8'); + echo $this->render(); + exit(1); + } + /** * Build the view for the message. *