Skip to content

[Config] Introducing the new param() function as early as possible #17673

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 0 commits into from

Conversation

ThomasLandauer
Copy link
Contributor

No description provided.


return static function (ContainerConfigurator $containerConfigurator) {
$containerConfigurator->extension('some_package', [
// any string surrounded by two % is replaced by that parameter value
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep comment for %% case ? Like for xml and yaml

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two counter-arguments:

  • (More important): It's explained right above the code block:

    wrap the parameter name in two % (e.g. %app.admin_email%):

  • (Less important): In PHP, env() should be shown as preferred way (IMO).

@carsonbot carsonbot changed the title Introducing the new param() function as early as possible [Config] Introducing the new param() function as early as possible Jun 6, 2023
@javiereguiluz
Copy link
Member

Thank you Thomas.

javiereguiluz added a commit to javiereguiluz/symfony-docs that referenced this pull request Jun 6, 2023
…s early as possible (ThomasLandauer)

This PR was squashed before being merged into the 5.4 branch.

Discussion
----------

[Config] Introducing the new `param()` function as early as possible

Commits
-------

a4c1261 [Config] Introducing the new `param()` function as early as possible
@javiereguiluz
Copy link
Member

Note: GitHub displays this PR as "closed", but it was fully merged. Thanks.

@ThomasLandauer ThomasLandauer deleted the patch-17 branch June 6, 2023 20:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants