function Debug::kint

Same name in other branches
  1. 4.x src/Twig/Extension/Debug.php \Drupal\devel\Twig\Extension\Debug::kint()

Similar to dump() but always uses the kint dumper if available.

Handles 0, 1, or multiple arguments.

Parameters

\Twig\Environment $env: The twig environment instance.

array $context: An array of parameters passed to the template.

array $args: An array of parameters passed the function.

Return value

string String representation of the input variables.

See also

\Drupal\devel\DevelDumperManager::dump()

File

src/Twig/Extension/Debug.php, line 148

Class

Debug
Provides the Devel debugging function within Twig templates.

Namespace

Drupal\devel\Twig\Extension

Code

public function kint(Environment $env, array $context, array $args = []) : string|false|null {
    return $this->doDump($env, $context, $args, 'kint');
}