How to add an extension in a Symfony 5.1 application without using bundles [closed]

In a Symfony 5.1 application, I’d like to have an application configuration file in config/packages/app.yaml that can be validated.

Starting from that validated configuration file I want to add all the values of the configuration file in the container as parameters.

The goal of this approach is to have some sort of documentation on the allowed values for the application.

An important note is that I don’t want to use any bundle as I’d have done in a Symfony 3.4 application where I’d have created a class extending the Extension class in the src/AppBundle/DependencyInjection folder.

Hope you’ll give me some hints here. Thanks 🙂

Source: Symfony Questions

Was this helpful?

0 / 0

Leave a Reply 0

Your email address will not be published. Required fields are marked *