diff --git a/bundles/best_practices.rst b/bundles/best_practices.rst index 2e1fd28fab8..af3da3970e1 100644 --- a/bundles/best_practices.rst +++ b/bundles/best_practices.rst @@ -306,26 +306,15 @@ following standardized instructions in your ``README.md`` file. ### Step 2: Enable the Bundle Then, enable the bundle by adding it to the list of registered bundles - in the `app/AppKernel.php` file of your project: + in the `config/bundles.php` file of your project: ```php - // app/AppKernel.php - - // ... - class AppKernel extends Kernel - { - public function registerBundles() - { - $bundles = [ - // ... - new \\(), - ]; - - // ... - } + // config/bundles.php + return [ // ... - } + \\::class => ['all' => true], + ]; ``` .. code-block:: rst @@ -362,26 +351,14 @@ following standardized instructions in your ``README.md`` file. ~~~~~~~~~~~~~~~~~~~~~~~~~ Then, enable the bundle by adding it to the list of registered bundles - in the ``app/AppKernel.php`` file of your project:: - - // app/AppKernel.php - - // ... - class AppKernel extends Kernel - { - public function registerBundles() - { - $bundles = [ - // ... - - new \\(), - ]; + in the ``config/bundles.php`` file of your project:: - // ... - } + // config/bundles.php + return [ // ... - } + \\::class => ['all' => true], + ]; .. _`installation chapter`: https://getcomposer.org/doc/00-intro.md