Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.6k
[OptionsResolver] Add new OptionConfigurator class to define options with fluent interface#33848
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Thanks@lmillucci for working on this feature :) I like it ! and congratulation for your first pull request.
I've left some comments to move as fast as we can, thanks again.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
src/Symfony/Component/OptionsResolver/Tests/OptionsResolverTest.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
src/Symfony/Component/OptionsResolver/Tests/OptionsResolverTest.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
src/Symfony/Component/OptionsResolver/Tests/OptionsResolverTest.php OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
something else we may want to consider, and what we did for DI configurators as well, is to make it truly fluid; $optionsResolver ->define('foo') ->required() ->define('bar') ->required(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
With minor comments.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
yceruto commentedOct 7, 2019 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
@lmillucci thanks for your work and for solving all comments. After the discussion we had about this#33848 (comment) where I suggest you to remove the annotation I'm sorry about that, and I hope you're okay. |
@yceruto no problem, I've easily restored |
@stof could you please review this PR again and have your vote on this ? thanks! |
ping @symfony/mergers ? |
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
3e44405
to8326c70
CompareReady for final reviews (the fabbot.io failure is a false positive) |
@lmillucci do you like to finish this proposal? |
lmillucci commentedJan 20, 2020 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
@yceruto Yes, what exception should be thrown when defining an already defined option? Something like |
@lmillucci yes, |
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
@lmillucci almost done :) you just need to rebase on |
1369e55
toe5f8397
Comparee5f8397
to519acba
Comparethere is a commit that don't belongs to this PRf825642 (the first one) could you please, fix it? thanks! |
519acba
to789dcfd
CompareThe component's CHANGELOG file should mention this change. |
…with fluent interface
Thank you@lmillucci. |
789dcfd
to1ff5640
Compare…define options with fluent interface (lmillucci, yceruto)This PR was merged into the 5.1-dev branch.Discussion----------[OptionsResolver] Add new OptionConfigurator class to define options with fluent interface| Q | A| ------------- | ---| Branch? | master| Bug fix? | no| New feature? | yes| Deprecations? | no| Tickets |Fix#33735| License | MIT| Doc PR |symfony/symfony-docs#12426- [x] submit changes to the documentationThis PR adds OptionConfigurator to the OptionsResolverCommits-------1ff5640 [OptionsResolver] Add new OptionConfigurator class to define options with fluent interface
…lucci)This PR was squashed before being merged into the master branch.Discussion----------[OptionResolver] Document the OptionConfiguratorAdd `define()` method to OptionResolver to enhance readability of option configuration. Seesymfony/symfony#33848Commits-------921c73f [OptionResolver] Document the OptionConfigurator
Uh oh!
There was an error while loading.Please reload this page.
This PR adds OptionConfigurator to the OptionsResolver