GraphQL Rust Codegen
The missing piece for offline-first applications 🚀
A powerful Rust CLI tool that transforms GraphQL schemas into production-ready database code. Built specifically for developers creating offline-first applications with Tauri, it bridges the gap between GraphQL APIs and local data persistence.
📦 Installation
From Crates.io (Recommended)
From Source
🚀 Quick Start
# Initialize your project
That's it! You'll get:
- Database entities with proper Rust types
- Migration files for schema setup
- Relationship mappings for foreign keys
- Type-safe ORM code ready for production
📚 Documentation
- Getting Started - Installation and basic usage
- Configuration - TOML/YAML setup and options
- Examples - Real-world integration examples
- Comparisons - How it stacks up against similar tools
- Reference - Type mappings and generated structure
- Contributing - Development setup and contribution guidelines
✨ Key Features
- 🔍 Dual Schema Support: GraphQL introspection + SDL file parsing
- 🗄️ Multi-ORM Ready: Diesel and Sea-ORM support out of the box
- 💾 Database Agnostic: SQLite, PostgreSQL, and MySQL
- 🔄 Migration Generation: Automatic SQL migration files
- 🔗 Smart Relationships: Foreign key detection and ORM relationships
- 🎯 Type Safety: Compile-time guarantees for your data layer
- ⚡ Performance: Native Rust speed with zero runtime overhead
- 🔧 Tauri Native: Seamless desktop app integration
🎯 Perfect For
- Offline-first Tauri applications
- Local data synchronization workflows
- Type-safe database layer generation
- Rapid GraphQL-to-SQL prototyping
- Enterprise data persistence needs
Ready to build offline-first apps with confidence? Dive into the Getting Started guide.
📄 License
MIT License - see LICENSE for details.