Built and maintained by n1ru4l
A GraphQL Codegen feature for bringing the benefits of Relay Compiler to any GraphQL Client using Relay Operation Optimizer
You can test how relay-compiler affects your queries over on the Relay Compiler REPL.
- Optimize your Operations TL;DR: reduce operation complexity and size
- Inline Fragments
- Flatten Transform
- Skip Redundant Node Transform
- FragmentArguments TL;DR: Make your fragments reusable with different arguments
Set up your project per the GraphQL Codegen Docs, and add
flattenGeneratedTypes: true in your codegen.yml:
Please notice that you have to skip the document validation - but no worries, relay-compiler will validate your documents instead!