no-root-type
Disallow using root types `mutation` and/or `subscription`.
💡 This rule provides suggestions
- Category:
Schema - Rule name:
@graphql-eslint/no-root-type - Requires GraphQL Schema:
trueℹ️ - Requires GraphQL Operations:
falseℹ️
Disallow using root types mutation and/or subscription.
Usage Examples
Incorrect
Correct
Config Schema
The schema defines the following properties:
disallow (array, required)
The elements of the array can contain the following enum values:
mutationsubscription
Additional restrictions:
- Minimum items:
1 - Unique items:
true