Requirements symfony bundle in AppKernel.php

352 views Asked by At

I created vendor bundle for symfony2

it has required bundle (such us liip/imagine-bundle).

in composer.php i insert necessary lines:

"require": {
    ...
    "liip/imagine-bundle": "1.3.0",
    ...
}

but i have error - Bundle "LiipImagineBundle" does not exist or it is not enabled. Maybe you forgot to add it in the registerBundles() method of your AppKernel.php file?

i can add it in AppKernel.php, but i think it is not good practice.

How i can use requirements bundles in my vendor bundle?

1

There are 1 answers

0
Andrii Mishchenko On

You do have to enable it in AppKernel::registerBundles method and it is considered as a right approach as mentioned here How to Install 3rd Party Bundles