-
-
Notifications
You must be signed in to change notification settings - Fork 9.7k
Closed
Description
Symfony Translation Component 4.2.2
When translating long strings that can be pluralized, splitting the parts often improves readability (and compliance with maximum line length code style rules):
$translator->trans(
'There must be at least one lower case letter.|'.
'There must be at least %count% lower case letter.',
['%count%' => $constraint->getMin()]
);
instead of
$translator->trans(
'There must be at least one lower case letter.|There must be at least %count% lower case letter.',
['%count%' => $constraint->getMin()]
);
The PhpExtractor does not recognize the string concatenation, but includes only the first string (There must be at least one lower case letter.|
in this case) in the extracted translations.