DEV Community


Discussion on: 4 reasons why you should use GraphQL over REST APIs

andrewbridge profile image
Andrew Bridge

I understand that this is always touted as a big plus of GraphQL, but it's absolutely possible to do this with a REST API, check out the spec for JSON:API, which allows nested entity relationships to be defined as part of a single request.

That aside, if you have control over the API you're querying, there's no reason you can't define an endpoint that includes all the data you need in a single request anyway, right?

Thread Thread
blessingartcreator profile image
Blessing Hirwa Author

REST can do it but Graphql uses low bandwidth compared to REST, that was my point.

Some comments have been hidden by the post's author - find out more