Open captbaritone opened 8 months ago
/** @gqlField */ export function nodes<T>(connection: Connection<T>): T[] { return connection.edge.map(edge => edge.node); }
Should act as a functional equivalent of a method on a generic class:
/** @gqlType */ class Connection<T> { // ... other fields/methods nodes(): T[] { return this.edges.map(edge => edge.node) } }
Should act as a functional equivalent of a method on a generic class: