How to var_dump variables in twig templates?

The Solution to How to var_dump variables in twig templates? is


As of Twig 1.5, the correct answer is to use the dump function. It is fully documented in the Twig documentation. Here is the documentation to enable this inside Symfony2.

{{ dump(user) }}

~ Answered on 2012-04-09 21:58:22


Most Viewed Questions: