diffql
v1.0.1
Published
GraphQL schema diff CLI tool
Maintainers
Readme
🔍 DiffQL
A blazing-fast CLI tool to detect breaking and non-breaking changes between two GraphQL schemas.
📦 Installation
Install globally via NPM:
npm install -g diffql🚀 Usage
diffql ./schemas/oldSchema.graphql ./schemas/newSchema.graphqlYou can also run directly using Node:
node src/index.js ./schemas/oldSchema.graphql ./schemas/newSchema.graphql✅ Output Example
🔍 Schema Diff Results:
❌ Breaking: Type 'User' removed
✅ Non-breaking: Type 'Post' added- ✅ Green: Non-breaking change (e.g., new types or fields)
- ❌ Red: Breaking change (e.g., removed types or required fields removed)
📖 Features
- 🔍 Detect breaking and non-breaking changes
- 🎨 Color-coded CLI output (tick/cross icons)
- 🛠 Works on any GraphQL schema file
- 🔁 Easily integratable into CI/CD
🗺 Roadmap (Coming Soon)
- 🚫 CI/CD enforcement mode (
--fail-on-breaking) - ⚙️ Custom rule engine via config file
- 🕘 Schema version history & timeline
- 🧠 Smart impact analysis
- 💻 VSCode extension
- 🌐 Web-based visual diff tool
- ☁️ Cloud dashboard + Slack integration
🧪 Testing
We use Jest for tests:
npm run test👨💻 Contributing
Pull requests and ideas are welcome!
- Fork the repo
- Create a feature branch
- Make your changes
- Submit a PR
📄 License
MIT License. Use it freely.
