Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

Twig String Extension

No security coverage Maintenance fixes only 25 sites

Part of the Twig ecosystem · 43 projects

This module allows Drupal to use the Symfony Unicode String library within Twig templates. This provides enhanced string manipulation capabilities directly in your templates. To enable this, you need to configure allowed classes in your Drupal settings file.

Adds support for the Twig String Extension library

Symfony Unicode String

In order to access the Symfony\Component\String\UnicodeString class in twig, you need to add it as an allowed class in your settings.php with the twig_sandbox_allowed_classes setting. For example:

$settings['twig_sandbox_allowed_classes'] = [
  'Symfony\Component\String\UnicodeString',
  'Drupal\Core\Template\Attribute',
];

See more on how this is processed in the TwigSandboxPolicy.

Drupal 9–11

Ask your assistant about Twig String Extension

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
2
Tracked since
May 2023
Latest release
7 months ago
Releases (12 mo)
1 ▲ from 0
Maintenance
Active

Releases

Version Type Core PHP Release date
1.0.2 Stable 9–11 Mar 30, 2026
1.0.1 Stable 9–10 May 19, 2023