PHPackages                             bitexpert/silex-twig-translation - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Localization &amp; i18n](/categories/localization)
4. /
5. bitexpert/silex-twig-translation

AbandonedArchivedLibrary[Localization &amp; i18n](/categories/localization)

bitexpert/silex-twig-translation
================================

Allows to use Symfony/Translation within a Silex / Twig application.

312PHP

Since Mar 24Pushed 14y ago1 watchersCompare

[ Source](https://github.com/bitExpert/silex-twig-translation)[ Packagist](https://packagist.org/packages/bitexpert/silex-twig-translation)[ RSS](/packages/bitexpert-silex-twig-translation/feed)WikiDiscussions master Synced today

READMEChangelogDependenciesVersions (1)Used By (0)

```
README
======

What is Silex Twig Translation Extension?
----------------

The Silex Twig Translation Extension as the name implies is an extension for
the Twig templating engine allowing to use Symfony/Translation within the
Twig templates of an Silex powered application.

Requirements
----------------

You will need a working Silex + Symfony/Translation + Twig application.

Setup Symfony/Translation provider:
	$app->register(new Silex\Provider\TranslationServiceProvider(), array(
		'locale_fallback'        => 'en',
		'translation.class_path' => 'vendor/symfony/src',
	));
	$app['translator.messages'] = array(
		'en' => 'locales/en.yml',
		'de' => 'locales/de.yml'
	);
	$app['translator.loader'] = new Symfony\Component\Translation\Loader\YamlFileLoader();

Setup Twig:
	$app->register(new Silex\Provider\TwigServiceProvider(), array(
		'twig.path'       => __DIR__.'/views',
		'twig.class_path' => __DIR__.'/vendor/twig/lib'
		)
	));

Register silex-twig-extension:
	$app['twig']->addExtension(new bitExpert_Silex_Twig_Translation_Extension());

How to use?
----------------

Example: {% translate my_translation_key %}

Will pass my_translation_key to Symfony/Translation and render the result within
the twig template.
```

###  Health Score

21

—

LowBetter than 18% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/1adf0ab660536efce10aeb97f0c90ec881110b64fbd23429fa945190df0def56?d=identicon)[shochdoerfer](/maintainers/shochdoerfer)

![](https://www.gravatar.com/avatar/ba0cd04f3918dcbc41e698cc49555cbf559ddfef7ddd05ccd64a85e7b377f48f?d=identicon)[bitExpert](/maintainers/bitExpert)

---

Top Contributors

[![shochdoerfer](https://avatars.githubusercontent.com/u/596449?v=4)](https://github.com/shochdoerfer "shochdoerfer (3 commits)")

### Embed Badge

![Health badge](/badges/bitexpert-silex-twig-translation/health.svg)

```
[![Health](https://phpackages.com/badges/bitexpert-silex-twig-translation/health.svg)](https://phpackages.com/packages/bitexpert-silex-twig-translation)
```

###  Alternatives

[smmoosavi/php-gettext

Wrapper for php-gettext by danilo segan. This library provides PHP functions to read MO files even when gettext is not compiled in or when appropriate locale is not present on the system.

1927.0k1](/packages/smmoosavi-php-gettext)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
