Registry / utility / symfony-translation-contracts

symfony-translation-contracts

JSON →
library3.7.0phppackagistunverified

Generic abstractions related to translation.

composer require symfony/translation-contracts
INSTALL
IMPORT
SIG · SYMFONY-TRANSLATIO
S
symfony-translation-contracts
utilityphpv3.7.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

TranslatorInterface
use Symfony\Contracts\Translation\TranslatorInterface;

Injects the translator interface and translates a message.

use Symfony\Contracts\Translation\TranslatorInterface; class MyService { public function __construct(private TranslatorInterface $translator) {} public function greet(): string { return $this->translator->trans('hello'); } }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
3.7.0latest on Packagist
Audit
Dependencies

No dependency data recorded yet.

Agent activity
12 hits · last 30 days
node
12
Resources
symfony-translation-contracts — pip install symfony-translation-contracts · libregistry