Extending the Graph
Adding a resolver
Adding a service
Adding a module
Generating schema files
It's important that once you've started on a schema extension that you to regenerate the schema. We leverage the generated schema to create types for front-end apps so they're super important! You can even extend the schema and generate types before you even write the related resolvers.
- Start the server for the back-end project
nx serve [project]
- In another terminal run the project schema generator
nx generate-graphql [project]
- In another terminal run the gateway schema generator
nx generate-graphql api-gateway
- Commit the changed schema.graphql files
+ apps/api-gateway/schema.graphql
+ apps/[project]/schema.graphql