Skip to main content

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.

  1. Start the server for the back-end project
nx serve [project]
  1. In another terminal run the project schema generator
nx generate-graphql [project]
  1. In another terminal run the gateway schema generator
nx generate-graphql api-gateway
  1. Commit the changed schema.graphql files
+ apps/api-gateway/schema.graphql
+ apps/[project]/schema.graphql