When debugging blade templates in Laravel 5.*, you often get meaningless error messages referring to cached views. But all of them used to be better: The debugging view in version 4 contained more helpful functions and was also visually more beautiful. With a few lines of code, you can get this functionality back with the help of whoops ("PHP errors for cool kids").
An exemplary error view looks like this in Laravel 5.4:
First you include the package "filp / whoops" in the dev block of composer.json:
Then you modify the rendering method, which is responsible for sending the exception to the browser:
Now you get the full code preview and other nice features like current environment variables: