Skip to Content
GraphQL Tools
DocumentationAPI@graphql-tools/utilssrcfunctionsshouldIncludeNode

Function: shouldIncludeNode()

shouldIncludeNode(variableValues, node): boolean

Defined in: packages/utils/src/collectFields.ts:178

Determines if a field should be included based on the @include and @skip directives, where @skip has higher precedence than @include.

Parameters

variableValues

any

node

FieldNode | FragmentSpreadNode | InlineFragmentNode

Returns

boolean