graphene-django-query-optimizer 0.9.0

Last updated:

0 purchases

graphene-django-query-optimizer 0.9.0 Image
graphene-django-query-optimizer 0.9.0 Images
Add to Cart

Description:

graphenedjangoqueryoptimizer 0.9.0

Graphene Django Query Optimizer








pip install graphene-django-query-optimizer


Documentation: https://mrthearman.github.io/graphene-django-query-optimizer/
Source Code: https://github.com/MrThearMan/graphene-django-query-optimizer/
Contributing: https://github.com/MrThearMan/graphene-django-query-optimizer/blob/main/CONTRIBUTING.md

Solve the GraphQL N+1 problem in graphene-django applications
just by changing a few imports, automatically adding the appropriate
only,
select_related,
and prefetch_related
method calls to your QuerySets to fetch only what you need.
import graphene
from example_project.app.models import Example

from query_optimizer import DjangoObjectType, DjangoListField

class ExampleType(DjangoObjectType):
class Meta:
model = Example

class Query(graphene.ObjectType):
all_examples = DjangoListField(ExampleType)

schema = graphene.Schema(query=Query)

License:

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Customer Reviews

There are no reviews.