Skip to content
This repository was archived by the owner on Aug 5, 2026. It is now read-only.
This repository was archived by the owner on Aug 5, 2026. It is now read-only.

ENSv2 GraphQL API: *Connection.totalCount #1692

Description

@shrugs
  • the totalCount field is pretty useful in a lot of contexts, but they definitely need it for subdomains and i hate the Domain.subdomainCount ergonomics
  • but pothos was being pretty shitty about being able to inject this correctly, since it doesn't provide the domain as parent (??) and only provides the connection object as parent (??) so what we actually need to do is probably more like "in the main connection resolver, if totalCount is selected, execute db.$count(domains) and return
  • totalCount in a Relay-style connection should reflect the filters applied to the connection, but ignore pagination arguments (like first, last, after, before)
  • replace Domain.subdomainCount with Domain.subdomains.totalCount

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

ensapiENSApi related

Projects

  • Status
    Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions