Skip to content

Consistency in form widget names #11458

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

Conversation

Korbeil
Copy link
Contributor

@Korbeil Korbeil commented Apr 19, 2019

Was working with symfony/form and was using form widget names with snake_case.
I needed some help with a simple bug and @lyrixx told me that we should not use snake_case.

But since I saw snake_case from the docs and I also saw camelCase I just made a pass to have camelCase everywhere for form widget names.

@OskarStark
Copy link
Contributor

Was the bug related to snake_case/camelCase?

@Korbeil
Copy link
Contributor Author

Korbeil commented Apr 20, 2019

I made a DTO witch camelCase attributes (like every class we usely do) and my form having snake_case widget names so error mapping was incorrect :/ So kind of yes.
The idea is just to enforce people using camelCase to have correct error mapping 😉

@javiereguiluz javiereguiluz added this to the 3.4 milestone Apr 23, 2019
@javiereguiluz
Copy link
Member

@Korbeil thank you ... and congrats on your first Symfony Docs contribution! We merged it in 3.4 branch and then we'll merge it in the other branches.

@Korbeil Korbeil deleted the consistency-in-form-widget-names branch April 23, 2019 08:11
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