Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
[Serializer] CamelCaseToSnakeCaseNameConverter upper camel case not working #21399
The CamelCaseToSnakeCaseNameConverter provides a constructor argument to specify whether to use lower camel case or not. Denormalizing upper camel case works fine, but normalizing
added a commit
Jan 25, 2017
referenced this issue
Jan 25, 2017
PascalCase is just another name for upper camel case - people often call things differently. However, the denormalize method supports it:
Why shouldn't the normalize method, too?
@theofidry as your last quote points it out, there is indeed two kind of camel case: lower and upper, PascalCase being a synonym of upper camelCase (also known as StudlyCaps). I was not aware of that but according to https://fr.wikipedia.org/wiki/CamelCase, it seems true.
Isn't "lower camel case" simply "camel case", whereas "upper camel case" is "pascal case"? The class/arguments are unclear in their current form. Two separate converter classes would be more appropriate.
Edit: We posted at the same time, but indeed, @chalasr, that would be much more intuitive.