class TwigNodeVisitor

Provides a Twig_NodeVisitor to change the generated parse-tree.

This is used to ensure that everything that is printed is wrapped via twig_render() function so that we can write for example just {{ content }} in templates instead of having to write {{ render(content) }}.

Hierarchy

  • class \Drupal\Core\Template\TwigNodeVisitor implements \Drupal\Core\Template\Twig_NodeVisitorInterface

Expanded class hierarchy of TwigNodeVisitor

See also

twig_render

File

drupal/core/lib/Drupal/Core/Template/TwigNodeVisitor.php, line 19
Definition of Drupal\Core\Template\TwigNodeVisitor.

Namespace

Drupal\Core\Template
View source

Members