Open timkelty opened 6 years ago
I'm doing this a little already. Any time you pull a list of entries, if you ask for the author
field I tack on ->with('author')
,
There's definitely some more places I can be doing this but I haven't gotten around to it yet. I'll look and see what sort of eager loading I can do on the entries/assets fields, next.
Not sure how feasible this would be, but ideally queries with nested element queries would employ eager-loading to improve performance: https://docs.craftcms.com/v3/dev/eager-loading-elements.html#app
Other n+1 discussion: https://github.com/markhuot/craftql/issues/150