Hacker News new | ask | show | jobs
by bluejekyll 1919 days ago
Additional GraphQL con: it requires some thought and planning in order to ensure data is cacheable in CDNs and other reverse proxies. This is generally simpler in REST because the APIs tend to be more single use. In GraphQL you have to essentially predefine all the queries in order to achieve the same cache-ability of responses. Then identify those, essentially, over REST.
1 comments

Solved: https://www.apollographql.com/docs/apollo-server/performance... 2-stage request.

1. Hashes queries and uses GET requests.

2. If missing, sends a standard graphql as POST