You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Submitting this as a question or discussion point, as much as an issue.
GraphQLTypeBuilder adds fields using ToCamelCase when the name isn't explicitly supplied. (The implementation just lowercases the first character).
What's the rationale behind this choice?
We're using code-first models reverse-engineered from a database where everything is uppercase; it means that to query a property we either have to explicitly add each one by name (user.AddField("USER_ID", u => u.USER_ID)), or our queries look a bit odd: "uSER_ID".
The text was updated successfully, but these errors were encountered:
The rationale for using camel case was that the convention for GraphQL is to use camel-case names. Since the convention for C# properties is Pascal case, the ToCamelCase function just lowercases the first letter.
Adding customization for this is a good idea, and should also be pretty simple to implement.
Submitting this as a question or discussion point, as much as an issue.
GraphQLTypeBuilder adds fields using ToCamelCase when the name isn't explicitly supplied. (The implementation just lowercases the first character).
What's the rationale behind this choice?
We're using code-first models reverse-engineered from a database where everything is uppercase; it means that to query a property we either have to explicitly add each one by name (
user.AddField("USER_ID", u => u.USER_ID)
), or our queries look a bit odd:"uSER_ID
".The text was updated successfully, but these errors were encountered: