spatie/laravel-ray
Send Laravel debug output to Ray, Spatie’s desktop debugging app. Use a consistent API to inspect variables, arrays, HTML, queries and more, measure performance, and pause execution. Works across Laravel/PHP with Ray’s rich UI.
dd(), dump(), and Log::debug() with a unified, interactive desktop tool (Ray). Reduces context-switching between terminal, browser, and IDE.@ray directives to inspect variables in views dynamically (e.g., debugging dynamic content generation).@measure directives.Adopt When:
dd() with interactive Ray panels).Look Elsewhere If:
dd() usage in a small team).*"Laravel-Ray lets our developers debug 10x faster by replacing clunky dd() calls with a real-time, interactive desktop dashboard—like Chrome DevTools for PHP. It’s a force multiplier for:
@ray directives in Blade/queries).ROI: "For every 1 hour saved per developer per week, this pays for itself in 3 months."
*"Laravel-Ray integrates Ray—a Swiss Army knife for debugging—into Laravel with zero config. Key wins:
dump(), Log::debug(), and dd() with @ray() (supports arrays, queries, Blade variables, and even Markdown).join is slow.@ray($variable) in views to inspect dynamic content (e.g., ‘Why is this loop breaking?’).@measure around critical code to find bottlenecks (e.g., ‘Why is this API endpoint taking 2s?’).How to Start:
composer require spatie/laravel-ray.php artisan ray:install and launch the Ray desktop app.dd($user) with @ray($user) in your code.Trade-offs:
How can I help you explore Laravel packages today?