signor_busi
07/15/2018, 9:29 AMquery {
posts (where: {...}) {
content
comments {
count // <- how to do this efficiently?
}
}
}
Robert
07/15/2018, 9:51 AMcomments
. Something like this:
type Comments {
comments: [Comment!]!
count: Int!
}
and then create the resolver with an aggregate like in the node tutorial: https://github.com/howtographql/graphql-js/blob/master/src/resolvers/Query.jsJames Bradly
07/16/2018, 4:28 AM