neo-graphql-ts-generator
por martinforsulu
Web & Frontend DevelopmentResumo
Automatically generates TypeScript types from GraphQL schema files with CLI integration for developers and AI agents.
Descrição
O que esta skill faz
Converts GraphQL schema files (.graphql, .gql) to TypeScript interfaces, types, unions, and enums via a CLI tool. Handles complex schema features including discriminated unions, interfaces, and nullability. Can process single files or batches.
Eliminates hand-writing TypeScript types that must stay in sync with a GraphQL schema, removing a common source of type drift.
Quando usá-la
- Generate TypeScript types from a REST-to-GraphQL migration
- Sync client-side types after backend schema updates
- Batch-convert all schemas in a monorepo at once
- Automate type generation in a CI pipeline
- Get typed interfaces from a third-party GraphQL API schema
Exemplo de fluxo de trabalho
User asks: Generate TypeScript types from /docs/api.graphql
- 1
Receives the schema file path from the user
- 2
Runs graphql-ts-generator /docs/api.graphql via CLI
- 3
Parser validates and converts the schema to an AST
- 4
Generator transforms AST nodes to TypeScript interfaces, unions, and enums
- 5
Writes output .ts files to the dist/ directory
TypeScript type files ready to import into the project
Instalação
clawhub install martinforsulu/neo-graphql-ts-generatorExecute o comando da CLI ou cole o prompt no Claude Code, Cursor, Codex ou no agente de código que você usa.