Create GraphQL schemas and resolvers with TypeScript using classes and decorators.
TypeGraphQL is a framework for building GraphQL APIs with TypeScript. It enables developers to define GraphQL schemas and resolvers using TypeScript classes and decorators, solving the problem of redundancy between schema definitions and data models. By providing a single source of truth, it improves developer experience and type safety.
Backend developers and teams building GraphQL APIs with TypeScript who want to reduce boilerplate, maintain type safety, and streamline schema development.
Developers choose TypeGraphQL because it eliminates the need to manually sync GraphQL SDL with TypeScript interfaces, offers built-in features like dependency injection and authorization guards, and enhances productivity with full IDE support and compile-time error checking.
Create GraphQL schema and resolvers with TypeScript, using classes and decorators!
Uses TypeScript classes as a single source of truth, automatically syncing GraphQL schema with data models to reduce boilerplate and prevent mismatches.
Provides compile-time type checking and IDE features like rename refactoring, catching errors early and boosting developer productivity.
Includes dependency injection for resolvers and authorization guards via decorators, simplifying common tasks like authentication and service management.
Offers a clean, declarative way to define types and resolvers using decorators, making code more readable and maintainable compared to manual SDL.
Requires TypeScript and experimental decorators, limiting use in plain JavaScript projects or teams averse to decorator syntax.
Involves understanding decorators and TypeGraphQL-specific patterns, which can be more complex than using simpler libraries like Apollo Server directly.
Some GraphQL tooling and community plugins may not integrate seamlessly with TypeGraphQL's class-based approach compared to SDL-first methods.
A tool for generating code based on a GraphQL schema and GraphQL operations (query/mutation/subscription), with flexible support for custom plugins.
Code-First, Type-Safe, GraphQL Schema Construction
🪄 Magical GraphQL query engine for TypeScript
Pothos GraphQL is library for creating GraphQL schemas in typescript using a strongly typed code first approach
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.