You are here

public function TwigThemeTokenParser::parse in Components! 8

File

src/Template/TwigThemeTokenParser.php, line 21

Class

TwigThemeTokenParser
Generates a render array and renders that.

Namespace

Drupal\components\Template

Code

public function parse(\Twig_Token $token) {
  $expr = $this->parser
    ->getExpressionParser()
    ->parseExpression();
  return new TwigNodeTheme($expr, $this
    ->parseArguments(), $token
    ->getLine(), $this
    ->getTag());
}