You are here

public function Token::getFunctions in Bamboo Twig 8.4

Same name and namespace in other branches
  1. 8.5 bamboo_twig_token/src/TwigExtension/Token.php \Drupal\bamboo_twig_token\TwigExtension\Token::getFunctions()
  2. 8.2 bamboo_twig_token/src/TwigExtension/Token.php \Drupal\bamboo_twig_token\TwigExtension\Token::getFunctions()
  3. 8.3 bamboo_twig_token/src/TwigExtension/Token.php \Drupal\bamboo_twig_token\TwigExtension\Token::getFunctions()

List of all Twig functions.

File

bamboo_twig_token/src/TwigExtension/Token.php, line 15

Class

Token
Provides a token rempalcement as Twig Extensions.

Namespace

Drupal\bamboo_twig_token\TwigExtension

Code

public function getFunctions() {
  return [
    new \Twig_SimpleFunction('bamboo_token', [
      $this,
      'substituteToken',
    ]),
  ];
}