Skip to content

Commit 73084d8

Browse files
committed
Merge branch '6.4' into 7.1
* 6.4: [Translation] fix: add nikic/php-parser requirement for translation:extract in tran…
2 parents 4de0df5 + ad92626 commit 73084d8

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

translation.rst

+11
Original file line numberDiff line numberDiff line change
@@ -457,6 +457,16 @@ The ``translation:extract`` command looks for missing translations in:
457457
* Any PHP file/class stored in the ``src/`` directory that uses
458458
:ref:`Constraints Attributes <validation-constraints>` with ``*message`` named argument(s).
459459

460+
.. tip::
461+
462+
Install the ``nikic/php-parser`` package in your project to improve the
463+
results of the ``translation:extract`` command. This package enables an
464+
`AST`_ parser that can find many more translatable items:
465+
466+
.. code-block:: terminal
467+
468+
$ composer require nikic/php-parser
469+
460470
.. _translation-resource-locations:
461471

462472
Translation Resource/File Names and Locations
@@ -1563,3 +1573,4 @@ Learn more
15631573
.. _`Loco (localise.biz)`: https://github.com/symfony/symfony/blob/{version}/src/Symfony/Component/Translation/Bridge/Loco/README.md
15641574
.. _`Lokalise`: https://github.com/symfony/symfony/blob/{version}/src/Symfony/Component/Translation/Bridge/Lokalise/README.md
15651575
.. _`Phrase`: https://github.com/symfony/symfony/blob/{version}/src/Symfony/Component/Translation/Bridge/Phrase/README.md
1576+
.. _`AST`: https://en.wikipedia.org/wiki/Abstract_syntax_tree

0 commit comments

Comments
 (0)