NoUnusedFragmentsRule.d.ts 478 B

12345678910111213
  1. import type { ASTVisitor } from '../../language/visitor';
  2. import type { ASTValidationContext } from '../ValidationContext';
  3. /**
  4. * No unused fragments
  5. *
  6. * A GraphQL document is only valid if all fragment definitions are spread
  7. * within operations, or spread within other fragments spread within operations.
  8. *
  9. * See https://spec.graphql.org/draft/#sec-Fragments-Must-Be-Used
  10. */
  11. export declare function NoUnusedFragmentsRule(
  12. context: ASTValidationContext,
  13. ): ASTVisitor;