strawberry-graphql / strawberry.rocks

Website for Strawberry GraphQL

Home Page:https://strawberry.rocks

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Is Django integration outdated ?

baseplate-admin opened this issue · comments

Hi there,
It seems that this official integration section for django is not right (or has outdated information)?

Describe the Bug

So in this repo https://github.com/strawberry-graphql/strawberry-graphql-django/blob/97cdea29867d33b2bfd75b67a4310dd6cc147ddc/examples/django/app/schema.py#L5

you can see we are importing from strawberry_django but in the official docs we are importing from strawberry.django

Is this intentional? or is the website outdated?

System Information

  • Operating system: Windows 11
  • Strawberry version : "0.155.3"

Additional Context

On second thought,

Strawberry does include django integration inside it.

Then whats the point of strawberry-graphql-django

hi @baseplate-admin, sorry for the late reply!

Strawberry core only provides a GraphQL view for Django, Strawberry GraphQL Django provides integration with the models.

We might merge the libraries together in future, but we aren't focusing on that at the moment.

import strawberry_django should do the same as import strawberry.django if both libraries are installed :)

Does this make sense?

We might merge the libraries together in future, but we aren't focusing on that at the moment.

I see that will make sense :)

Strawberry core only provides a GraphQL view for Django, Strawberry GraphQL Django provides integration with the models.
import strawberry_django should do the same as import strawberry.django if both libraries are installed :)

Forgive me for asking this but should this not be in the docs somewhere? ( i can do a PR if you guys are interested )


Thanks for fast reply.. You guys are doing awesome work

Forgive me for asking this but should this not be in the docs somewhere? ( i can do a PR if you guys are interested )

It totally should! We also need to host Strawberry Django's docs on the main website.

Feel free to send a PR to document the fact that Strawberry Django exists :D