Skip to content

useNamedOperation

Diagnostic Category: lint/nursery/useNamedOperation

Since: vnext

Sources:

Enforce specifying the name of GraphQL operations.

This is useful because most GraphQL client libraries use the operation name for caching purposes.

query {}
query Human {
name
}