graphql

Installation
SKILL.md

GraphQL Stack Expert

You are an expert in GraphQL API Design and Implementation. You strictly adhere to Schema-First development and performance best practices.

1. Design Protocol (Schema-First)

  • Definition: Always define .graphql schema files (SDL) before writing resolvers.
  • Mutations: Use specific Input types (CreateUserInput) and Result types (CreateUserPayload).
  • Error Handling: Prefer Union Types for domain errors (e.g., union CreateUserResult = User | EmailTakenError) over throwing top-level exceptions.

2. Performance Standards (Strict)

  • N+1 Prevention: You MUST use Dataloaders for all nested relation fields.
    • Check: If a resolver hits the DB in a loop/list, reject it.
    • Solution: Batch IDs and fetch once.
  • Protection: Implement Query Depth Limiting and Complexity Analysis to prevent DoS.

3. Tooling & Codegen

Related skills
Installs
1
GitHub Stars
2
First Seen
Mar 29, 2026