I do not know if this has advantages: should I remove unused services from the service container?
For example, in the configuration of my package, I can disable the use of the lang option provider:
my_bundle: providers: lang: enabled: false
When the lang provider is enabled, the provider tag must be added. This service is defined in the services.xml file and is loaded through the extension:
<service id="my_bundle.provider.lang" class="My\Provider\LangOptionsProvider">
So, it is a good idea to remove this definition and why?
public function load(array $configs, ContainerBuilder $container) {
source share