codegen.yml 738 B

1234567891011121314151617181920212223242526272829303132
  1. overwrite: true
  2. schema: '../query-node/generated/graphql-server/generated/schema.graphql'
  3. documents:
  4. - './src/graphql/queries/*.graphql'
  5. config:
  6. scalars:
  7. Date: Date
  8. preResolveTypes: true # avoid using Pick
  9. skipTypename: true # skip __typename field in typings unless it's part of the query
  10. generates:
  11. src/graphql/generated/schema.ts:
  12. hooks:
  13. afterOneFileWrite:
  14. - prettier --write
  15. - eslint --fix
  16. plugins:
  17. - typescript
  18. src/graphql/generated/queries.ts:
  19. preset: import-types
  20. presetConfig:
  21. typesPath: ./schema
  22. hooks:
  23. afterOneFileWrite:
  24. - prettier --write
  25. - eslint --fix
  26. plugins:
  27. - typescript-operations
  28. - typescript-document-nodes