selectionSet static method

SelectionSetNode selectionSet(
  1. List<SelectionNode> selections
)

Creates a SelectionSetNode from a list of selections.

This helper provides a cleaner way to create nested selection sets.

Example:

selectionSet([
  field('number'),
  field('types'),
])

Implementation

static SelectionSetNode selectionSet(List<SelectionNode> selections) {
  return SelectionSetNode(selections: selections);
}