Liking cljdoc? Tell your friends :D

com.walmartlabs.lacinia.parser

Parse a query document using a compiled schema.

Also provides functions that operate on the parsed query.

Parse a query document using a compiled schema.

Also provides functions that operate on the parsed query.
raw docstring

Directiveclj

source

FieldSelectionclj

source

FragmentDefinitionclj

source

InlineFragmentclj

source

NamedFragmentclj

source

operationsclj

(operations parsed-query)

Given a previously parsed query, this returns a map of two keys:

:type : The type of request, one of: :query, :mutation, or :subscription.

:operations : The names of the top-level operations, as a set of keywords.

Given a previously parsed query, this returns a map of two keys:

:type
: The type of request, one of: :query, :mutation, or :subscription.

:operations
: The names of the top-level operations, as a set of keywords.
sourceraw docstring

parse-queryclj

(parse-query schema query-document)
(parse-query schema query-document operation-name)
(parse-query schema query-document operation-name timing-start)

Given a compiled schema and a query document, parses the query to an executable form as well as performing a number of validations.

When the request containing the query document provides an operation name, that is provided and the parsed query executes just that operation.

Given a compiled schema and a query document, parses the query to an executable form
as well as performing a number of validations.

When the request containing the query document provides an operation name, that is provided
and the parsed query executes just that operation.
sourceraw docstring

prepare-with-query-variablesclj

(prepare-with-query-variables parsed-query variables)

Given a parsed query data structure and a map of variables, update the query, calculating field arguments and applying @skip and @include directives.

Given a parsed query data structure and a map of variables,
update the query, calculating field arguments and applying @skip and @include directives.
sourceraw docstring

summarize-queryclj

(summarize-query parsed-query)

Analyzes a parsed query, returning a summary string.

The summary superficially resembles a GraphQL query, but strips out aliases, directives, and field arguments. In addition, fragments (both inline and named) are collapsed into their containing selections.

This summary can act as a 'fingerprint' of a related set of queries and is typically used in query performance analysis.

Analyzes a parsed query, returning a summary string.

The summary superficially resembles a GraphQL query, but
strips out aliases, directives, and field arguments. In addition, fragments (both inline and named)
are collapsed into their containing selections.

This summary can act as a 'fingerprint' of a related set of queries and is typically used
in query performance analysis.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close