View array content in twig

The dump function dumps information about a template variable. It can be used as an alternative to var_dump or print_r from php. This is mostly useful to debug a template that does not behave as expected by introspecting its variables:


{{ dump(var_name) }}

Read entire article at: Twig -> Functions -> dump

Leave a Reply

Your email address will not be published. Required fields are marked *