getDirectivesFromAttachments function

Iterable<DirectiveNode> getDirectivesFromAttachments(
  1. GraphQLAttachments attachments
)

Implementation

Iterable<DirectiveNode> getDirectivesFromAttachments(
  GraphQLAttachments attachments,
) {
  return attachments.whereType<DirectiveNode>().followedBy(
        attachments.whereType<ToDirectiveValue>().map((e) => e.directiveValue),
      );
}