nest icon indicating copy to clipboard operation
nest copied to clipboard

graphql federation code/schema examples are not correct

Open dberardo-com opened this issue 8 months ago • 5 comments
trafficstars

Is there an existing issue for this?

  • [x] I have searched the existing issues

Current behavior

the example should not be using introspectAndCompose which is not production ready. they should be using auto generated typings files, like in the doc: https://docs.nestjs.com/graphql/federation#schema-first-1

even better would be if the schema first example was showing a way to generate the .gql schema files from an npm run command and both the schema-first and the code-first had an example of how to merge the schemas into a single file in the gateway folder, perhaps using the generate-typings script: https://docs.nestjs.com/graphql/quick-start#schema-first

Minimum reproduction code

no

Steps to reproduce

No response

Expected behavior

no

Package

  • [ ] I don't know. Or some 3rd-party package
  • [ ] @nestjs/common
  • [ ] @nestjs/core
  • [ ] @nestjs/microservices
  • [ ] @nestjs/platform-express
  • [ ] @nestjs/platform-fastify
  • [ ] @nestjs/platform-socket.io
  • [ ] @nestjs/platform-ws
  • [ ] @nestjs/testing
  • [ ] @nestjs/websockets
  • [ ] Other (see below)

Other package

No response

NestJS version

No response

Packages versions


Node.js version

No response

In which operating systems have you tested?

  • [ ] macOS
  • [ ] Windows
  • [ ] Linux

Other

No response

dberardo-com avatar Feb 21 '25 11:02 dberardo-com