Where can I get the amount of direct descendants of a comment? - eviltoast

I’m creating an AGPL-licensed Lemmy web UI.

While working on the comment section I wondered: what’s the best way to retrieve the total amount of direct descendants of a comment? I’m not talking about child_count as this appears to count descendants at any depth.

My use case is displaying a ‘Load X more’ button that for a given comment loads any direct descendants that are not yet being displayed.