graphene-django-extras
graphene-django-extras copied to clipboard
"totalCount" field stays camelCase when auto_camelcase == False
Our GraphQL schema uses snake_case, so we have auto_camelcase
switched off:
schema = graphene.Schema(query=Query, mutation=Mutation, auto_camelcase=False)
This works fine for everything except for the totalCount
field since it's hardcoded here:
https://github.com/eamigo86/graphene-django-extras/blob/ddc2ed921bd915be16234f4a9761108508cbd49f/graphene_django_extras/types.py#L313
Which means our queries:
{
projects(title_text__icontains: "create") {
totalCount
results {
id
title_text
}
}
}
and results:
{
"data": {
"projects": {
"totalCount": 1,
"results": [
{
"id": "1",
"title_text": "Create Notification Stack"
}
]
}
}
}
end up with inconsistent styling.