|
|
|
|
|
by tango12
981 days ago
|
|
I think there are 2 subtleties here on where you optimize perf: 1. Frontend makes n+1 requests to the api. Either use GraphQL or build a custom endpoint that shapes a perfect response. 2. Build an api server that fetches data from the db efficiently without n+1 hitting the DB. The whole tension introduced with resolver/data-loader ways of building GraphQL, is that while it makes 1 easy, it makes 2 harder. Compared to bespoke REST-ish endpoints. |
|