Skip to content

Commit 737cc7f

Browse files
committed
Minor reword
1 parent f2d0eba commit 737cc7f

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

bundles/best_practices.rst

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -517,9 +517,12 @@ The ``composer.json`` file should include at least the following metadata:
517517

518518
``autoload``
519519
This information is used by Symfony to load the classes of the bundle. It's
520-
recommended to use the `PSR-4`_ autoload standard. Use the namespace as key,
520+
recommended to use the `PSR-4`_ autoload standard: use the namespace as key,
521521
and the location of the bundle's main class (relative to ``composer.json``)
522-
as value, example: ``"autoload": { "psr-4": { "JohnSmith\\BlogBundle\\": "" } }``
522+
as value. For example, if the main class is located in the bundle root
523+
directory: ``"autoload": { "psr-4": { "SomeVendor\\BlogBundle\\": "" } }``.
524+
If the main class is located in the ``src/`` directory of the bundle:
525+
``"autoload": { "psr-4": { "SomeVendor\\BlogBundle\\": "src/" } }``.
523526

524527
In order to make it easier for developers to find your bundle, register it on
525528
`Packagist`_, the official repository for Composer packages.

0 commit comments

Comments
 (0)