A hands-on GraphQL playground where I experiment with core and advanced GraphQL concepts, focusing on schema design, pagination patterns, and performance optimizations
- GraphQL
- TypeScript
- MongoDB
- pnpm — package manager
- Bun — JavaScript runtime
- Docker / Docker Compose — local database setup
.
├── data-loader/ # DataLoader patterns and batching strategies
├── schema/ # GraphQL schemas and type definitions
├── server.ts # Entry point that spins up the GraphQL server
├── docker-compose.yml # MongoDB service for local development
- Object Types
- Queries & Mutations
- Cursor-based Pagination
- Node Interface (implemented for the Post schema)
- Schema-to-Schema Navigation
- MongoDB integration
- DataLoader usage to prevent N+1 query problems
Install dependencies
pnpm installStart MongoDB
docker-compose up -dRun the GraphQL server
pnpm devAfter starting the server, GraphQL introspection and the GraphiQL interface are available at:
http://localhost:3000/graphqlThis repository serves as a learning lab to explore GraphQL best practices, experiment with different architectural approaches, and validate performance strategies such as cursor-based pagination and DataLoader batching.