Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

Twig VarDumper

Security covered Under active development 6,891 sites

Part of the Twig ecosystem · 43 projects

This module enhances Twig debugging by providing improved `dump()` and `vardumper()` functions. These functions allow you to easily inspect and debug Twig variables within your templates, offering a more detailed and user-friendly output compared to default methods.

Provides a way to display Twig PHP variables in a pretty way.

Twig VarDumper provides a better {{ dump() }} and {{ vardumper() }} function that can help you debug Twig variables.

API functions

  • {{ dump() }} Show all variables y current template. Replaced default {{ dump() }} from Twig Debug.php using symfony/var-dumper
  • {{ dump(variable_name) }} Show current variable informartion using symfony/var-dumper
  • {{ vardumper() }} Show all variables y current template using symfony/var-dumper
  • {{ vardumper(variable_name) }} Show current variable informartion using symfony/var-dumper

INSTALLATION

On Drupal 11.x.x, install the module using CLI:

  1. Require and install the module and its dependencies
    • composer config repositories.drupal composer https://packages.drupal.org/11
    • composer require drupal/twig_vardumper:^3

Configure Drupal to work

  1. Set development environment for twig
    • Uncomnet in settings.local.php file $settings['container_yamls'][] = DRUPAL_ROOT . '/sites/development.services.yml'; line
    • Add in development.services.yml
    • parameters:
      twig.config:
      debug: true

DEMO

Drupal 10–11

Ask your assistant about Twig VarDumper

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
4
Tracked since
Jan 2024
Latest release
3 months ago
Releases (12 mo)
1 ▲ from 0
Maintenance
Active

Release Timeline

Releases

Version Type Core PHP Release date
3.2.1 Stable 10–11 Aug 18, 2026
3.2.0 Stable 9–11 Sep 12, 2024
3.2.x-dev Dev 10–11 Sep 12, 2024
3.1.1 Stable 9–10 Jan 18, 2024