graphql 17.0.0-beta.1 → 17.0.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/__dev__/devMode.d.ts +1 -1
- package/__dev__/error/GraphQLError.d.ts +1 -1
- package/__dev__/error/ensureGraphQLError.d.ts +1 -1
- package/__dev__/error/index.d.ts +1 -1
- package/__dev__/error/locatedError.d.ts +1 -1
- package/__dev__/error/syntaxError.d.ts +1 -1
- package/__dev__/execution/AbortedGraphQLExecutionError.d.ts +1 -1
- package/__dev__/execution/AsyncWorkTracker.d.ts +1 -1
- package/__dev__/execution/ExecutionArgs.d.mts +1 -0
- package/__dev__/execution/ExecutionArgs.d.ts +1 -0
- package/__dev__/execution/ExecutionArgs.js +3 -0
- package/__dev__/execution/ExecutionArgs.mjs +3 -0
- package/__dev__/execution/Executor.d.ts +1 -1
- package/__dev__/execution/ExecutorThrowingOnIncremental.d.ts +1 -1
- package/__dev__/execution/buildResolveInfo.d.ts +1 -1
- package/__dev__/execution/cancellablePromise.d.ts +1 -1
- package/__dev__/execution/collectFields.d.ts +1 -1
- package/__dev__/execution/collectIteratorPromises.d.ts +1 -1
- package/__dev__/execution/createSharedExecutionContext.d.ts +1 -1
- package/__dev__/execution/execute.d.ts +1 -1
- package/__dev__/execution/getStreamUsage.d.ts +1 -1
- package/__dev__/execution/getVariableSignature.d.ts +1 -1
- package/__dev__/execution/hooks.d.ts +1 -1
- package/__dev__/execution/incremental/Computation.d.ts +1 -1
- package/__dev__/execution/incremental/IncrementalExecutor.d.ts +1 -1
- package/__dev__/execution/incremental/IncrementalPublisher.d.ts +1 -1
- package/__dev__/execution/incremental/Queue.d.ts +1 -1
- package/__dev__/execution/incremental/WorkQueue.d.ts +1 -1
- package/__dev__/execution/incremental/buildExecutionPlan.d.ts +1 -1
- package/__dev__/execution/index.d.ts +1 -1
- package/__dev__/execution/legacyIncremental/BranchingIncrementalExecutor.d.mts +1 -0
- package/__dev__/execution/legacyIncremental/BranchingIncrementalExecutor.d.ts +1 -0
- package/__dev__/execution/legacyIncremental/BranchingIncrementalExecutor.js +3 -0
- package/__dev__/execution/legacyIncremental/BranchingIncrementalExecutor.mjs +3 -0
- package/__dev__/execution/legacyIncremental/BranchingIncrementalPublisher.d.mts +1 -0
- package/__dev__/execution/legacyIncremental/BranchingIncrementalPublisher.d.ts +1 -0
- package/__dev__/execution/legacyIncremental/BranchingIncrementalPublisher.js +3 -0
- package/__dev__/execution/legacyIncremental/BranchingIncrementalPublisher.mjs +3 -0
- package/__dev__/execution/legacyIncremental/legacyExecuteIncrementally.d.mts +1 -0
- package/__dev__/execution/legacyIncremental/legacyExecuteIncrementally.d.ts +1 -0
- package/__dev__/execution/legacyIncremental/legacyExecuteIncrementally.js +3 -0
- package/__dev__/execution/legacyIncremental/legacyExecuteIncrementally.mjs +3 -0
- package/__dev__/execution/mapAsyncIterable.d.ts +1 -1
- package/__dev__/execution/returnIteratorCatchingErrors.d.ts +1 -1
- package/__dev__/execution/values.d.ts +1 -1
- package/__dev__/execution/withConcurrentAbruptClose.d.ts +1 -1
- package/__dev__/graphql.d.ts +1 -1
- package/__dev__/harness.d.ts +1 -1
- package/__dev__/index.d.ts +1 -1
- package/__dev__/jsutils/AccumulatorMap.d.ts +1 -1
- package/__dev__/jsutils/Maybe.d.ts +1 -1
- package/__dev__/jsutils/ObjMap.d.ts +1 -1
- package/__dev__/jsutils/Path.d.ts +1 -1
- package/__dev__/jsutils/PromiseOrValue.d.ts +1 -1
- package/__dev__/jsutils/capitalize.d.ts +1 -1
- package/__dev__/jsutils/devAssert.d.ts +1 -1
- package/__dev__/jsutils/didYouMean.d.ts +1 -1
- package/__dev__/jsutils/formatList.d.ts +1 -1
- package/__dev__/jsutils/getBySet.d.ts +1 -1
- package/__dev__/jsutils/groupBy.d.ts +1 -1
- package/__dev__/jsutils/identityFunc.d.ts +1 -1
- package/__dev__/jsutils/inspect.d.ts +1 -1
- package/__dev__/jsutils/instanceOf.d.ts +1 -1
- package/__dev__/jsutils/invariant.d.ts +1 -1
- package/__dev__/jsutils/isAsyncIterable.d.ts +1 -1
- package/__dev__/jsutils/isIterableObject.d.ts +1 -1
- package/__dev__/jsutils/isObjectLike.d.ts +1 -1
- package/__dev__/jsutils/isPromise.d.ts +1 -1
- package/__dev__/jsutils/isSameSet.d.ts +1 -1
- package/__dev__/jsutils/keyMap.d.ts +1 -1
- package/__dev__/jsutils/keyValMap.d.ts +1 -1
- package/__dev__/jsutils/mapValue.d.ts +1 -1
- package/__dev__/jsutils/memoize1.d.ts +1 -1
- package/__dev__/jsutils/memoize2.d.ts +1 -1
- package/__dev__/jsutils/memoize3.d.ts +1 -1
- package/__dev__/jsutils/naturalCompare.d.ts +1 -1
- package/__dev__/jsutils/printPathArray.d.ts +1 -1
- package/__dev__/jsutils/promiseForObject.d.ts +1 -1
- package/__dev__/jsutils/promiseReduce.d.ts +1 -1
- package/__dev__/jsutils/promiseWithResolvers.d.ts +1 -1
- package/__dev__/jsutils/suggestionList.d.ts +1 -1
- package/__dev__/jsutils/toError.d.ts +1 -1
- package/__dev__/jsutils/toObjMap.d.ts +1 -1
- package/__dev__/language/KindTypeMap.d.ts +1 -1
- package/__dev__/language/ast.d.ts +1 -1
- package/__dev__/language/blockString.d.ts +1 -1
- package/__dev__/language/characterClasses.d.ts +1 -1
- package/__dev__/language/directiveLocation.d.ts +1 -1
- package/__dev__/language/index.d.ts +1 -1
- package/__dev__/language/kinds.d.ts +1 -1
- package/__dev__/language/kinds_.d.ts +1 -1
- package/__dev__/language/lexer.d.ts +1 -1
- package/__dev__/language/location.d.ts +1 -1
- package/__dev__/language/parser.d.ts +1 -1
- package/__dev__/language/predicates.d.ts +1 -1
- package/__dev__/language/printLocation.d.ts +1 -1
- package/__dev__/language/printString.d.ts +1 -1
- package/__dev__/language/printer.d.ts +1 -1
- package/__dev__/language/schemaCoordinateLexer.d.ts +1 -1
- package/__dev__/language/source.d.ts +1 -1
- package/__dev__/language/tokenKind.d.ts +1 -1
- package/__dev__/language/visitor.d.ts +1 -1
- package/__dev__/type/assertName.d.ts +1 -1
- package/__dev__/type/definition.d.ts +1 -1
- package/__dev__/type/directives.d.ts +1 -1
- package/__dev__/type/index.d.ts +1 -1
- package/__dev__/type/introspection.d.ts +1 -1
- package/__dev__/type/scalars.d.ts +1 -1
- package/__dev__/type/schema.d.ts +1 -1
- package/__dev__/type/validate.d.ts +1 -1
- package/__dev__/utilities/TypeInfo.d.ts +1 -1
- package/__dev__/utilities/astFromValue.d.ts +1 -1
- package/__dev__/utilities/buildASTSchema.d.ts +1 -1
- package/__dev__/utilities/buildClientSchema.d.ts +1 -1
- package/__dev__/utilities/coerceInputValue.d.ts +1 -1
- package/__dev__/utilities/concatAST.d.ts +1 -1
- package/__dev__/utilities/extendSchema.d.ts +1 -1
- package/__dev__/utilities/findSchemaChanges.d.ts +1 -1
- package/__dev__/utilities/getDefaultValueAST.d.ts +1 -1
- package/__dev__/utilities/getIntrospectionQuery.d.ts +1 -1
- package/__dev__/utilities/getOperationAST.d.ts +1 -1
- package/__dev__/utilities/index.d.ts +1 -1
- package/__dev__/utilities/introspectionFromSchema.d.ts +1 -1
- package/__dev__/utilities/lexicographicSortSchema.d.ts +1 -1
- package/__dev__/utilities/mapSchemaConfig.d.ts +1 -1
- package/__dev__/utilities/printSchema.d.ts +1 -1
- package/__dev__/utilities/replaceVariables.d.ts +1 -1
- package/__dev__/utilities/resolveSchemaCoordinate.d.ts +1 -1
- package/__dev__/utilities/separateOperations.d.ts +1 -1
- package/__dev__/utilities/sortValueNode.d.ts +1 -1
- package/__dev__/utilities/stripIgnoredCharacters.d.ts +1 -1
- package/__dev__/utilities/typeComparators.d.ts +1 -1
- package/__dev__/utilities/typeFromAST.d.ts +1 -1
- package/__dev__/utilities/typedQueryDocumentNode.d.ts +1 -1
- package/__dev__/utilities/validateInputValue.d.ts +1 -1
- package/__dev__/utilities/valueFromAST.d.ts +1 -1
- package/__dev__/utilities/valueFromASTUntyped.d.ts +1 -1
- package/__dev__/utilities/valueToLiteral.d.ts +1 -1
- package/__dev__/validation/ValidationContext.d.ts +1 -1
- package/__dev__/validation/index.d.ts +1 -1
- package/__dev__/validation/rules/DeferStreamDirectiveLabelRule.d.ts +1 -1
- package/__dev__/validation/rules/DeferStreamDirectiveOnRootFieldRule.d.ts +1 -1
- package/__dev__/validation/rules/DeferStreamDirectiveOnValidOperationsRule.d.ts +1 -1
- package/__dev__/validation/rules/ExecutableDefinitionsRule.d.ts +1 -1
- package/__dev__/validation/rules/FieldsOnCorrectTypeRule.d.ts +1 -1
- package/__dev__/validation/rules/FragmentsOnCompositeTypesRule.d.ts +1 -1
- package/__dev__/validation/rules/KnownArgumentNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/KnownDirectivesRule.d.ts +1 -1
- package/__dev__/validation/rules/KnownFragmentNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/KnownOperationTypesRule.d.ts +1 -1
- package/__dev__/validation/rules/KnownTypeNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/LoneAnonymousOperationRule.d.ts +1 -1
- package/__dev__/validation/rules/LoneSchemaDefinitionRule.d.ts +1 -1
- package/__dev__/validation/rules/MaxIntrospectionDepthRule.d.ts +1 -1
- package/__dev__/validation/rules/NoFragmentCyclesRule.d.ts +1 -1
- package/__dev__/validation/rules/NoUndefinedVariablesRule.d.ts +1 -1
- package/__dev__/validation/rules/NoUnusedFragmentsRule.d.ts +1 -1
- package/__dev__/validation/rules/NoUnusedVariablesRule.d.ts +1 -1
- package/__dev__/validation/rules/OverlappingFieldsCanBeMergedRule.d.ts +1 -1
- package/__dev__/validation/rules/PossibleFragmentSpreadsRule.d.ts +1 -1
- package/__dev__/validation/rules/PossibleTypeExtensionsRule.d.ts +1 -1
- package/__dev__/validation/rules/ProvidedRequiredArgumentsRule.d.ts +1 -1
- package/__dev__/validation/rules/ScalarLeafsRule.d.ts +1 -1
- package/__dev__/validation/rules/SingleFieldSubscriptionsRule.d.ts +1 -1
- package/__dev__/validation/rules/StreamDirectiveOnListFieldRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueArgumentDefinitionNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueArgumentNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueDirectiveNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueDirectivesPerLocationRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueEnumValueNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueFieldDefinitionNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueFragmentNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueInputFieldNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueOperationNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueOperationTypesRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueTypeNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/UniqueVariableNamesRule.d.ts +1 -1
- package/__dev__/validation/rules/ValuesOfCorrectTypeRule.d.ts +1 -1
- package/__dev__/validation/rules/VariablesAreInputTypesRule.d.ts +1 -1
- package/__dev__/validation/rules/VariablesInAllowedPositionRule.d.ts +1 -1
- package/__dev__/validation/rules/custom/NoDeprecatedCustomRule.d.ts +1 -1
- package/__dev__/validation/rules/custom/NoSchemaIntrospectionCustomRule.d.ts +1 -1
- package/__dev__/validation/specifiedRules.d.ts +1 -1
- package/__dev__/validation/validate.d.ts +1 -1
- package/__dev__/version.d.ts +1 -1
- package/devMode.d.mts +29 -0
- package/devMode.d.ts +29 -0
- package/devMode.js.map +1 -1
- package/devMode.mjs.map +1 -1
- package/error/GraphQLError.d.mts +94 -10
- package/error/GraphQLError.d.ts +94 -10
- package/error/GraphQLError.js +11 -20
- package/error/GraphQLError.js.map +1 -1
- package/error/GraphQLError.mjs +11 -20
- package/error/GraphQLError.mjs.map +1 -1
- package/error/ensureGraphQLError.d.mts +2 -0
- package/error/ensureGraphQLError.d.ts +2 -0
- package/error/ensureGraphQLError.js +0 -3
- package/error/ensureGraphQLError.js.map +1 -1
- package/error/ensureGraphQLError.mjs +0 -3
- package/error/ensureGraphQLError.mjs.map +1 -1
- package/error/index.d.mts +6 -0
- package/error/index.d.ts +6 -0
- package/error/index.js.map +1 -1
- package/error/index.mjs.map +1 -1
- package/error/locatedError.d.mts +20 -0
- package/error/locatedError.d.ts +20 -0
- package/error/locatedError.js +0 -6
- package/error/locatedError.js.map +1 -1
- package/error/locatedError.mjs +0 -6
- package/error/locatedError.mjs.map +1 -1
- package/error/syntaxError.d.mts +15 -0
- package/error/syntaxError.d.ts +15 -0
- package/error/syntaxError.js +0 -4
- package/error/syntaxError.js.map +1 -1
- package/error/syntaxError.mjs +0 -4
- package/error/syntaxError.mjs.map +1 -1
- package/execution/AbortedGraphQLExecutionError.d.mts +27 -0
- package/execution/AbortedGraphQLExecutionError.d.ts +27 -0
- package/execution/AbortedGraphQLExecutionError.js.map +1 -1
- package/execution/AbortedGraphQLExecutionError.mjs.map +1 -1
- package/execution/AsyncWorkTracker.d.mts +1 -1
- package/execution/AsyncWorkTracker.d.ts +1 -1
- package/execution/AsyncWorkTracker.js +1 -5
- package/execution/AsyncWorkTracker.js.map +1 -1
- package/execution/AsyncWorkTracker.mjs +1 -5
- package/execution/AsyncWorkTracker.mjs.map +1 -1
- package/execution/ExecutionArgs.d.mts +101 -0
- package/execution/ExecutionArgs.d.ts +101 -0
- package/execution/ExecutionArgs.js +3 -0
- package/execution/ExecutionArgs.js.map +1 -0
- package/execution/ExecutionArgs.mjs +2 -0
- package/execution/ExecutionArgs.mjs.map +1 -0
- package/execution/Executor.d.mts +44 -40
- package/execution/Executor.d.ts +44 -40
- package/execution/Executor.js +2 -122
- package/execution/Executor.js.map +1 -1
- package/execution/Executor.mjs +2 -122
- package/execution/Executor.mjs.map +1 -1
- package/execution/ExecutorThrowingOnIncremental.js +0 -2
- package/execution/ExecutorThrowingOnIncremental.js.map +1 -1
- package/execution/ExecutorThrowingOnIncremental.mjs +0 -2
- package/execution/ExecutorThrowingOnIncremental.mjs.map +1 -1
- package/execution/buildResolveInfo.d.mts +2 -0
- package/execution/buildResolveInfo.d.ts +2 -0
- package/execution/buildResolveInfo.js +0 -3
- package/execution/buildResolveInfo.js.map +1 -1
- package/execution/buildResolveInfo.mjs +0 -3
- package/execution/buildResolveInfo.mjs.map +1 -1
- package/execution/cancellablePromise.d.mts +3 -0
- package/execution/cancellablePromise.d.ts +3 -0
- package/execution/cancellablePromise.js.map +1 -1
- package/execution/cancellablePromise.mjs.map +1 -1
- package/execution/collectFields.d.mts +10 -4
- package/execution/collectFields.d.ts +10 -4
- package/execution/collectFields.js +0 -41
- package/execution/collectFields.js.map +1 -1
- package/execution/collectFields.mjs +0 -41
- package/execution/collectFields.mjs.map +1 -1
- package/execution/collectIteratorPromises.d.mts +2 -0
- package/execution/collectIteratorPromises.d.ts +2 -0
- package/execution/collectIteratorPromises.js +0 -5
- package/execution/collectIteratorPromises.js.map +1 -1
- package/execution/collectIteratorPromises.mjs +0 -5
- package/execution/collectIteratorPromises.mjs.map +1 -1
- package/execution/createSharedExecutionContext.d.mts +1 -0
- package/execution/createSharedExecutionContext.d.ts +1 -0
- package/execution/createSharedExecutionContext.js.map +1 -1
- package/execution/createSharedExecutionContext.mjs.map +1 -1
- package/execution/execute.d.mts +403 -38
- package/execution/execute.d.ts +403 -38
- package/execution/execute.js +0 -161
- package/execution/execute.js.map +1 -1
- package/execution/execute.mjs +0 -161
- package/execution/execute.mjs.map +1 -1
- package/execution/getStreamUsage.d.mts +4 -1
- package/execution/getStreamUsage.d.ts +4 -1
- package/execution/getStreamUsage.js +0 -7
- package/execution/getStreamUsage.js.map +1 -1
- package/execution/getStreamUsage.mjs +0 -7
- package/execution/getStreamUsage.mjs.map +1 -1
- package/execution/getVariableSignature.d.mts +4 -1
- package/execution/getVariableSignature.d.ts +4 -1
- package/execution/getVariableSignature.js +0 -2
- package/execution/getVariableSignature.js.map +1 -1
- package/execution/getVariableSignature.mjs +0 -2
- package/execution/getVariableSignature.mjs.map +1 -1
- package/execution/hooks.d.mts +3 -7
- package/execution/hooks.d.ts +3 -7
- package/execution/hooks.js +0 -1
- package/execution/hooks.js.map +1 -1
- package/execution/hooks.mjs +0 -1
- package/execution/hooks.mjs.map +1 -1
- package/execution/incremental/Computation.d.mts +1 -1
- package/execution/incremental/Computation.d.ts +1 -1
- package/execution/incremental/Computation.js +0 -1
- package/execution/incremental/Computation.js.map +1 -1
- package/execution/incremental/Computation.mjs +0 -1
- package/execution/incremental/Computation.mjs.map +1 -1
- package/execution/incremental/IncrementalExecutor.d.mts +124 -9
- package/execution/incremental/IncrementalExecutor.d.ts +124 -9
- package/execution/incremental/IncrementalExecutor.js +1 -31
- package/execution/incremental/IncrementalExecutor.js.map +1 -1
- package/execution/incremental/IncrementalExecutor.mjs +1 -31
- package/execution/incremental/IncrementalExecutor.mjs.map +1 -1
- package/execution/incremental/IncrementalPublisher.d.mts +1 -3
- package/execution/incremental/IncrementalPublisher.d.ts +1 -3
- package/execution/incremental/IncrementalPublisher.js +0 -5
- package/execution/incremental/IncrementalPublisher.js.map +1 -1
- package/execution/incremental/IncrementalPublisher.mjs +0 -5
- package/execution/incremental/IncrementalPublisher.mjs.map +1 -1
- package/execution/incremental/Queue.js +3 -64
- package/execution/incremental/Queue.js.map +1 -1
- package/execution/incremental/Queue.mjs +2 -62
- package/execution/incremental/Queue.mjs.map +1 -1
- package/execution/incremental/WorkQueue.d.mts +8 -0
- package/execution/incremental/WorkQueue.d.ts +8 -0
- package/execution/incremental/WorkQueue.js +0 -15
- package/execution/incremental/WorkQueue.js.map +1 -1
- package/execution/incremental/WorkQueue.mjs +0 -15
- package/execution/incremental/WorkQueue.mjs.map +1 -1
- package/execution/incremental/buildExecutionPlan.d.mts +3 -0
- package/execution/incremental/buildExecutionPlan.d.ts +3 -0
- package/execution/incremental/buildExecutionPlan.js.map +1 -1
- package/execution/incremental/buildExecutionPlan.mjs.map +1 -1
- package/execution/index.d.mts +12 -3
- package/execution/index.d.ts +12 -3
- package/execution/index.js +4 -1
- package/execution/index.js.map +1 -1
- package/execution/index.mjs +1 -0
- package/execution/index.mjs.map +1 -1
- package/execution/legacyIncremental/BranchingIncrementalExecutor.d.mts +175 -0
- package/execution/legacyIncremental/BranchingIncrementalExecutor.d.ts +175 -0
- package/execution/legacyIncremental/BranchingIncrementalExecutor.js +69 -0
- package/execution/legacyIncremental/BranchingIncrementalExecutor.js.map +1 -0
- package/execution/legacyIncremental/BranchingIncrementalExecutor.mjs +65 -0
- package/execution/legacyIncremental/BranchingIncrementalExecutor.mjs.map +1 -0
- package/execution/legacyIncremental/BranchingIncrementalPublisher.d.mts +12 -0
- package/execution/legacyIncremental/BranchingIncrementalPublisher.d.ts +12 -0
- package/execution/legacyIncremental/BranchingIncrementalPublisher.js +131 -0
- package/execution/legacyIncremental/BranchingIncrementalPublisher.js.map +1 -0
- package/execution/legacyIncremental/BranchingIncrementalPublisher.mjs +127 -0
- package/execution/legacyIncremental/BranchingIncrementalPublisher.mjs.map +1 -0
- package/execution/legacyIncremental/legacyExecuteIncrementally.d.mts +165 -0
- package/execution/legacyIncremental/legacyExecuteIncrementally.d.ts +165 -0
- package/execution/legacyIncremental/legacyExecuteIncrementally.js +17 -0
- package/execution/legacyIncremental/legacyExecuteIncrementally.js.map +1 -0
- package/execution/legacyIncremental/legacyExecuteIncrementally.mjs +13 -0
- package/execution/legacyIncremental/legacyExecuteIncrementally.mjs.map +1 -0
- package/execution/mapAsyncIterable.d.mts +2 -0
- package/execution/mapAsyncIterable.d.ts +2 -0
- package/execution/mapAsyncIterable.js +0 -5
- package/execution/mapAsyncIterable.js.map +1 -1
- package/execution/mapAsyncIterable.mjs +0 -5
- package/execution/mapAsyncIterable.mjs.map +1 -1
- package/execution/returnIteratorCatchingErrors.d.mts +1 -0
- package/execution/returnIteratorCatchingErrors.d.ts +1 -0
- package/execution/returnIteratorCatchingErrors.js +0 -1
- package/execution/returnIteratorCatchingErrors.js.map +1 -1
- package/execution/returnIteratorCatchingErrors.mjs +0 -1
- package/execution/returnIteratorCatchingErrors.mjs.map +1 -1
- package/execution/values.d.mts +187 -5
- package/execution/values.d.ts +187 -5
- package/execution/values.js +14 -55
- package/execution/values.js.map +1 -1
- package/execution/values.mjs +14 -55
- package/execution/values.mjs.map +1 -1
- package/execution/withConcurrentAbruptClose.d.mts +2 -0
- package/execution/withConcurrentAbruptClose.d.ts +2 -0
- package/execution/withConcurrentAbruptClose.js +0 -14
- package/execution/withConcurrentAbruptClose.js.map +1 -1
- package/execution/withConcurrentAbruptClose.mjs +0 -14
- package/execution/withConcurrentAbruptClose.mjs.map +1 -1
- package/graphql.d.mts +192 -44
- package/graphql.d.ts +192 -44
- package/graphql.js +0 -12
- package/graphql.js.map +1 -1
- package/graphql.mjs +0 -12
- package/graphql.mjs.map +1 -1
- package/harness.d.mts +17 -0
- package/harness.d.ts +17 -0
- package/harness.js.map +1 -1
- package/harness.mjs.map +1 -1
- package/index.d.mts +26 -24
- package/index.d.ts +26 -24
- package/index.js +9 -96
- package/index.js.map +1 -1
- package/index.mjs +5 -149
- package/index.mjs.map +1 -1
- package/jsutils/AccumulatorMap.d.mts +2 -0
- package/jsutils/AccumulatorMap.d.ts +2 -0
- package/jsutils/AccumulatorMap.js +0 -4
- package/jsutils/AccumulatorMap.js.map +1 -1
- package/jsutils/AccumulatorMap.mjs +0 -4
- package/jsutils/AccumulatorMap.mjs.map +1 -1
- package/jsutils/Maybe.d.mts +5 -1
- package/jsutils/Maybe.d.ts +5 -1
- package/jsutils/Maybe.js.map +1 -1
- package/jsutils/Maybe.mjs.map +1 -1
- package/jsutils/ObjMap.d.mts +6 -0
- package/jsutils/ObjMap.d.ts +6 -0
- package/jsutils/ObjMap.js.map +1 -1
- package/jsutils/ObjMap.mjs.map +1 -1
- package/jsutils/Path.d.mts +30 -0
- package/jsutils/Path.d.ts +30 -0
- package/jsutils/Path.js +0 -6
- package/jsutils/Path.js.map +1 -1
- package/jsutils/Path.mjs +0 -6
- package/jsutils/Path.mjs.map +1 -1
- package/jsutils/PromiseOrValue.d.mts +1 -0
- package/jsutils/PromiseOrValue.d.ts +1 -0
- package/jsutils/PromiseOrValue.js.map +1 -1
- package/jsutils/PromiseOrValue.mjs.map +1 -1
- package/jsutils/capitalize.d.mts +2 -0
- package/jsutils/capitalize.d.ts +2 -0
- package/jsutils/capitalize.js +0 -3
- package/jsutils/capitalize.js.map +1 -1
- package/jsutils/capitalize.mjs +0 -3
- package/jsutils/capitalize.mjs.map +1 -1
- package/jsutils/devAssert.d.mts +1 -0
- package/jsutils/devAssert.d.ts +1 -0
- package/jsutils/devAssert.js.map +1 -1
- package/jsutils/devAssert.mjs.map +1 -1
- package/jsutils/didYouMean.d.mts +4 -1
- package/jsutils/didYouMean.d.ts +4 -1
- package/jsutils/didYouMean.js.map +1 -1
- package/jsutils/didYouMean.mjs.map +1 -1
- package/jsutils/formatList.d.mts +6 -2
- package/jsutils/formatList.d.ts +6 -2
- package/jsutils/formatList.js +0 -6
- package/jsutils/formatList.js.map +1 -1
- package/jsutils/formatList.mjs +0 -6
- package/jsutils/formatList.mjs.map +1 -1
- package/jsutils/getBySet.d.mts +1 -0
- package/jsutils/getBySet.d.ts +1 -0
- package/jsutils/getBySet.js.map +1 -1
- package/jsutils/getBySet.mjs.map +1 -1
- package/jsutils/groupBy.d.mts +2 -0
- package/jsutils/groupBy.d.ts +2 -0
- package/jsutils/groupBy.js +0 -3
- package/jsutils/groupBy.js.map +1 -1
- package/jsutils/groupBy.mjs +0 -3
- package/jsutils/groupBy.mjs.map +1 -1
- package/jsutils/identityFunc.d.mts +2 -0
- package/jsutils/identityFunc.d.ts +2 -0
- package/jsutils/identityFunc.js +0 -3
- package/jsutils/identityFunc.js.map +1 -1
- package/jsutils/identityFunc.mjs +0 -3
- package/jsutils/identityFunc.mjs.map +1 -1
- package/jsutils/inspect.d.mts +2 -0
- package/jsutils/inspect.d.ts +2 -0
- package/jsutils/inspect.js +0 -4
- package/jsutils/inspect.js.map +1 -1
- package/jsutils/inspect.mjs +0 -4
- package/jsutils/inspect.mjs.map +1 -1
- package/jsutils/instanceOf.d.mts +2 -0
- package/jsutils/instanceOf.d.ts +2 -0
- package/jsutils/instanceOf.js +1 -12
- package/jsutils/instanceOf.js.map +1 -1
- package/jsutils/instanceOf.mjs +1 -12
- package/jsutils/instanceOf.mjs.map +1 -1
- package/jsutils/invariant.d.mts +1 -0
- package/jsutils/invariant.d.ts +1 -0
- package/jsutils/invariant.js.map +1 -1
- package/jsutils/invariant.mjs.map +1 -1
- package/jsutils/isAsyncIterable.d.mts +2 -0
- package/jsutils/isAsyncIterable.d.ts +2 -0
- package/jsutils/isAsyncIterable.js +0 -4
- package/jsutils/isAsyncIterable.js.map +1 -1
- package/jsutils/isAsyncIterable.mjs +0 -4
- package/jsutils/isAsyncIterable.mjs.map +1 -1
- package/jsutils/isIterableObject.d.mts +6 -5
- package/jsutils/isIterableObject.d.ts +6 -5
- package/jsutils/isIterableObject.js +0 -17
- package/jsutils/isIterableObject.js.map +1 -1
- package/jsutils/isIterableObject.mjs +0 -17
- package/jsutils/isIterableObject.mjs.map +1 -1
- package/jsutils/isObjectLike.d.mts +2 -0
- package/jsutils/isObjectLike.d.ts +2 -0
- package/jsutils/isObjectLike.js +0 -4
- package/jsutils/isObjectLike.js.map +1 -1
- package/jsutils/isObjectLike.mjs +0 -4
- package/jsutils/isObjectLike.mjs.map +1 -1
- package/jsutils/isPromise.d.mts +3 -0
- package/jsutils/isPromise.d.ts +3 -0
- package/jsutils/isPromise.js +0 -4
- package/jsutils/isPromise.js.map +1 -1
- package/jsutils/isPromise.mjs +0 -4
- package/jsutils/isPromise.mjs.map +1 -1
- package/jsutils/isSameSet.d.mts +1 -0
- package/jsutils/isSameSet.d.ts +1 -0
- package/jsutils/isSameSet.js.map +1 -1
- package/jsutils/isSameSet.mjs.map +1 -1
- package/jsutils/keyMap.d.mts +7 -14
- package/jsutils/keyMap.d.ts +7 -14
- package/jsutils/keyMap.js +0 -27
- package/jsutils/keyMap.js.map +1 -1
- package/jsutils/keyMap.mjs +0 -27
- package/jsutils/keyMap.mjs.map +1 -1
- package/jsutils/keyValMap.d.mts +9 -6
- package/jsutils/keyValMap.d.ts +9 -6
- package/jsutils/keyValMap.js +0 -17
- package/jsutils/keyValMap.js.map +1 -1
- package/jsutils/keyValMap.mjs +0 -17
- package/jsutils/keyValMap.mjs.map +1 -1
- package/jsutils/mapValue.d.mts +2 -0
- package/jsutils/mapValue.d.ts +2 -0
- package/jsutils/mapValue.js +0 -4
- package/jsutils/mapValue.js.map +1 -1
- package/jsutils/mapValue.mjs +0 -4
- package/jsutils/mapValue.mjs.map +1 -1
- package/jsutils/memoize1.d.mts +2 -0
- package/jsutils/memoize1.d.ts +2 -0
- package/jsutils/memoize1.js +0 -3
- package/jsutils/memoize1.js.map +1 -1
- package/jsutils/memoize1.mjs +0 -3
- package/jsutils/memoize1.mjs.map +1 -1
- package/jsutils/memoize2.d.mts +2 -0
- package/jsutils/memoize2.d.ts +2 -0
- package/jsutils/memoize2.js +0 -3
- package/jsutils/memoize2.js.map +1 -1
- package/jsutils/memoize2.mjs +0 -3
- package/jsutils/memoize2.mjs.map +1 -1
- package/jsutils/memoize3.d.mts +2 -0
- package/jsutils/memoize3.d.ts +2 -0
- package/jsutils/memoize3.js +0 -3
- package/jsutils/memoize3.js.map +1 -1
- package/jsutils/memoize3.mjs +0 -3
- package/jsutils/memoize3.mjs.map +1 -1
- package/jsutils/naturalCompare.d.mts +1 -0
- package/jsutils/naturalCompare.d.ts +1 -0
- package/jsutils/naturalCompare.js +0 -7
- package/jsutils/naturalCompare.js.map +1 -1
- package/jsutils/naturalCompare.mjs +0 -7
- package/jsutils/naturalCompare.mjs.map +1 -1
- package/jsutils/printPathArray.d.mts +2 -0
- package/jsutils/printPathArray.d.ts +2 -0
- package/jsutils/printPathArray.js +0 -3
- package/jsutils/printPathArray.js.map +1 -1
- package/jsutils/printPathArray.mjs +0 -3
- package/jsutils/printPathArray.mjs.map +1 -1
- package/jsutils/promiseForObject.d.mts +2 -0
- package/jsutils/promiseForObject.d.ts +2 -0
- package/jsutils/promiseForObject.js +0 -7
- package/jsutils/promiseForObject.js.map +1 -1
- package/jsutils/promiseForObject.mjs +0 -7
- package/jsutils/promiseForObject.mjs.map +1 -1
- package/jsutils/promiseReduce.d.mts +2 -0
- package/jsutils/promiseReduce.d.ts +2 -0
- package/jsutils/promiseReduce.js +0 -7
- package/jsutils/promiseReduce.js.map +1 -1
- package/jsutils/promiseReduce.mjs +0 -7
- package/jsutils/promiseReduce.mjs.map +1 -1
- package/jsutils/promiseWithResolvers.d.mts +2 -0
- package/jsutils/promiseWithResolvers.d.ts +2 -0
- package/jsutils/promiseWithResolvers.js +0 -5
- package/jsutils/promiseWithResolvers.js.map +1 -1
- package/jsutils/promiseWithResolvers.mjs +0 -5
- package/jsutils/promiseWithResolvers.mjs.map +1 -1
- package/jsutils/suggestionList.d.mts +2 -0
- package/jsutils/suggestionList.d.ts +2 -0
- package/jsutils/suggestionList.js +1 -24
- package/jsutils/suggestionList.js.map +1 -1
- package/jsutils/suggestionList.mjs +1 -24
- package/jsutils/suggestionList.mjs.map +1 -1
- package/jsutils/toError.d.mts +2 -0
- package/jsutils/toError.d.ts +2 -0
- package/jsutils/toError.js +0 -3
- package/jsutils/toError.js.map +1 -1
- package/jsutils/toError.mjs +0 -3
- package/jsutils/toError.mjs.map +1 -1
- package/jsutils/toObjMap.d.mts +2 -0
- package/jsutils/toObjMap.d.ts +2 -0
- package/jsutils/toObjMap.js.map +1 -1
- package/jsutils/toObjMap.mjs.map +1 -1
- package/language/KindTypeMap.d.mts +1 -0
- package/language/KindTypeMap.d.ts +1 -0
- package/language/KindTypeMap.js.map +1 -1
- package/language/KindTypeMap.mjs.map +1 -1
- package/language/ast.d.mts +413 -53
- package/language/ast.d.ts +413 -53
- package/language/ast.js +0 -20
- package/language/ast.js.map +1 -1
- package/language/ast.mjs +0 -20
- package/language/ast.mjs.map +1 -1
- package/language/blockString.d.mts +1 -3
- package/language/blockString.d.ts +1 -3
- package/language/blockString.js +11 -37
- package/language/blockString.js.map +1 -1
- package/language/blockString.mjs +11 -37
- package/language/blockString.mjs.map +1 -1
- package/language/characterClasses.js +2 -45
- package/language/characterClasses.js.map +1 -1
- package/language/characterClasses.mjs +2 -45
- package/language/characterClasses.mjs.map +1 -1
- package/language/directiveLocation.d.mts +24 -5
- package/language/directiveLocation.d.ts +24 -5
- package/language/directiveLocation.js +0 -5
- package/language/directiveLocation.js.map +1 -1
- package/language/directiveLocation.mjs +0 -5
- package/language/directiveLocation.mjs.map +1 -1
- package/language/index.d.mts +6 -0
- package/language/index.d.ts +6 -0
- package/language/index.js +0 -4
- package/language/index.js.map +1 -1
- package/language/index.mjs +0 -4
- package/language/index.mjs.map +1 -1
- package/language/kinds.d.mts +3 -0
- package/language/kinds.d.ts +3 -0
- package/language/kinds.js.map +1 -1
- package/language/kinds.mjs.map +1 -1
- package/language/kinds_.d.mts +100 -12
- package/language/kinds_.d.ts +100 -12
- package/language/kinds_.js +0 -13
- package/language/kinds_.js.map +1 -1
- package/language/kinds_.mjs +0 -13
- package/language/kinds_.mjs.map +1 -1
- package/language/lexer.d.mts +48 -15
- package/language/lexer.d.ts +48 -15
- package/language/lexer.js +37 -278
- package/language/lexer.js.map +1 -1
- package/language/lexer.mjs +37 -278
- package/language/lexer.mjs.map +1 -1
- package/language/location.d.mts +16 -3
- package/language/location.d.ts +16 -3
- package/language/location.js +0 -4
- package/language/location.js.map +1 -1
- package/language/location.mjs +0 -4
- package/language/location.mjs.map +1 -1
- package/language/parser.d.mts +224 -9
- package/language/parser.d.ts +224 -9
- package/language/parser.js +0 -375
- package/language/parser.js.map +1 -1
- package/language/parser.mjs +0 -375
- package/language/parser.mjs.map +1 -1
- package/language/predicates.d.mts +181 -0
- package/language/predicates.d.ts +181 -0
- package/language/predicates.js +0 -6
- package/language/predicates.js.map +1 -1
- package/language/predicates.mjs +0 -6
- package/language/predicates.mjs.map +1 -1
- package/language/printLocation.d.mts +28 -0
- package/language/printLocation.d.ts +28 -0
- package/language/printLocation.js +0 -8
- package/language/printLocation.js.map +1 -1
- package/language/printLocation.mjs +0 -8
- package/language/printLocation.mjs.map +1 -1
- package/language/printString.d.mts +2 -0
- package/language/printString.d.ts +2 -0
- package/language/printString.js +5 -11
- package/language/printString.js.map +1 -1
- package/language/printString.mjs +5 -11
- package/language/printString.mjs.map +1 -1
- package/language/printer.d.mts +12 -0
- package/language/printer.d.ts +12 -0
- package/language/printer.js +0 -25
- package/language/printer.js.map +1 -1
- package/language/printer.mjs +0 -25
- package/language/printer.mjs.map +1 -1
- package/language/schemaCoordinateLexer.d.mts +14 -0
- package/language/schemaCoordinateLexer.d.ts +14 -0
- package/language/schemaCoordinateLexer.js +5 -35
- package/language/schemaCoordinateLexer.js.map +1 -1
- package/language/schemaCoordinateLexer.mjs +5 -35
- package/language/schemaCoordinateLexer.mjs.map +1 -1
- package/language/source.d.mts +28 -1
- package/language/source.d.ts +28 -1
- package/language/source.js +0 -12
- package/language/source.js.map +1 -1
- package/language/source.mjs +0 -12
- package/language/source.mjs.map +1 -1
- package/language/tokenKind.d.mts +5 -0
- package/language/tokenKind.d.ts +5 -0
- package/language/tokenKind.js +0 -4
- package/language/tokenKind.js.map +1 -1
- package/language/tokenKind.mjs +0 -4
- package/language/tokenKind.mjs.map +1 -1
- package/language/visitor.d.mts +182 -72
- package/language/visitor.d.ts +182 -72
- package/language/visitor.js +0 -15
- package/language/visitor.js.map +1 -1
- package/language/visitor.mjs +0 -15
- package/language/visitor.mjs.map +1 -1
- package/package.json +1 -1
- package/type/assertName.d.mts +18 -1
- package/type/assertName.d.ts +18 -1
- package/type/assertName.js +0 -8
- package/type/assertName.js.map +1 -1
- package/type/assertName.mjs +0 -8
- package/type/assertName.mjs.map +1 -1
- package/type/definition.d.mts +3258 -128
- package/type/definition.d.ts +3258 -128
- package/type/definition.js +5 -252
- package/type/definition.js.map +1 -1
- package/type/definition.mjs +5 -252
- package/type/definition.mjs.map +1 -1
- package/type/directives.d.mts +209 -20
- package/type/directives.d.ts +209 -20
- package/type/directives.js +0 -37
- package/type/directives.js.map +1 -1
- package/type/directives.mjs +0 -37
- package/type/directives.mjs.map +1 -1
- package/type/index.d.mts +6 -0
- package/type/index.d.ts +6 -0
- package/type/index.js +0 -23
- package/type/index.js.map +1 -1
- package/type/index.mjs +5 -48
- package/type/index.mjs.map +1 -1
- package/type/introspection.d.mts +36 -0
- package/type/introspection.d.ts +36 -0
- package/type/introspection.js +1 -6
- package/type/introspection.js.map +1 -1
- package/type/introspection.mjs +1 -6
- package/type/introspection.mjs.map +1 -1
- package/type/scalars.d.mts +29 -2
- package/type/scalars.d.ts +29 -2
- package/type/scalars.js +0 -15
- package/type/scalars.js.map +1 -1
- package/type/scalars.mjs +0 -15
- package/type/scalars.mjs.map +1 -1
- package/type/schema.d.mts +507 -31
- package/type/schema.d.ts +507 -31
- package/type/schema.js +0 -97
- package/type/schema.js.map +1 -1
- package/type/schema.mjs +0 -97
- package/type/schema.mjs.map +1 -1
- package/type/validate.d.mts +32 -3
- package/type/validate.d.ts +32 -3
- package/type/validate.js +0 -112
- package/type/validate.js.map +1 -1
- package/type/validate.mjs +0 -112
- package/type/validate.mjs.map +1 -1
- package/utilities/TypeInfo.d.mts +564 -1
- package/utilities/TypeInfo.d.ts +564 -1
- package/utilities/TypeInfo.js +1 -24
- package/utilities/TypeInfo.js.map +1 -1
- package/utilities/TypeInfo.mjs +1 -24
- package/utilities/TypeInfo.mjs.map +1 -1
- package/utilities/astFromValue.d.mts +36 -3
- package/utilities/astFromValue.d.ts +36 -3
- package/utilities/astFromValue.js +0 -42
- package/utilities/astFromValue.js.map +1 -1
- package/utilities/astFromValue.mjs +0 -42
- package/utilities/astFromValue.mjs.map +1 -1
- package/utilities/buildASTSchema.d.mts +66 -6
- package/utilities/buildASTSchema.d.ts +66 -6
- package/utilities/buildASTSchema.js +0 -21
- package/utilities/buildASTSchema.js.map +1 -1
- package/utilities/buildASTSchema.mjs +0 -21
- package/utilities/buildASTSchema.mjs.map +1 -1
- package/utilities/buildClientSchema.d.mts +17 -2
- package/utilities/buildClientSchema.d.ts +17 -2
- package/utilities/buildClientSchema.js +1 -32
- package/utilities/buildClientSchema.js.map +1 -1
- package/utilities/buildClientSchema.mjs +0 -30
- package/utilities/buildClientSchema.mjs.map +1 -1
- package/utilities/coerceInputValue.d.mts +83 -1
- package/utilities/coerceInputValue.d.ts +83 -1
- package/utilities/coerceInputValue.js +21 -50
- package/utilities/coerceInputValue.js.map +1 -1
- package/utilities/coerceInputValue.mjs +21 -50
- package/utilities/coerceInputValue.mjs.map +1 -1
- package/utilities/concatAST.d.mts +12 -0
- package/utilities/concatAST.d.ts +12 -0
- package/utilities/concatAST.js +0 -5
- package/utilities/concatAST.js.map +1 -1
- package/utilities/concatAST.mjs +0 -5
- package/utilities/concatAST.mjs.map +1 -1
- package/utilities/extendSchema.d.mts +58 -3
- package/utilities/extendSchema.d.ts +58 -3
- package/utilities/extendSchema.js +0 -60
- package/utilities/extendSchema.js.map +1 -1
- package/utilities/extendSchema.mjs +0 -60
- package/utilities/extendSchema.mjs.map +1 -1
- package/utilities/findSchemaChanges.d.mts +99 -1
- package/utilities/findSchemaChanges.d.ts +99 -1
- package/utilities/findSchemaChanges.js +3 -35
- package/utilities/findSchemaChanges.js.map +1 -1
- package/utilities/findSchemaChanges.mjs +3 -35
- package/utilities/findSchemaChanges.mjs.map +1 -1
- package/utilities/getDefaultValueAST.d.mts +1 -0
- package/utilities/getDefaultValueAST.d.ts +1 -0
- package/utilities/getDefaultValueAST.js +0 -2
- package/utilities/getDefaultValueAST.js.map +1 -1
- package/utilities/getDefaultValueAST.mjs +0 -2
- package/utilities/getDefaultValueAST.mjs.map +1 -1
- package/utilities/getIntrospectionQuery.d.mts +132 -0
- package/utilities/getIntrospectionQuery.d.ts +132 -0
- package/utilities/getIntrospectionQuery.js +0 -4
- package/utilities/getIntrospectionQuery.js.map +1 -1
- package/utilities/getIntrospectionQuery.mjs +0 -4
- package/utilities/getIntrospectionQuery.mjs.map +1 -1
- package/utilities/getOperationAST.d.mts +15 -0
- package/utilities/getOperationAST.d.ts +15 -0
- package/utilities/getOperationAST.js +0 -8
- package/utilities/getOperationAST.js.map +1 -1
- package/utilities/getOperationAST.mjs +0 -8
- package/utilities/getOperationAST.mjs.map +1 -1
- package/utilities/index.d.mts +18 -3
- package/utilities/index.d.ts +18 -3
- package/utilities/index.js +0 -27
- package/utilities/index.js.map +1 -1
- package/utilities/index.mjs +4 -37
- package/utilities/index.mjs.map +1 -1
- package/utilities/introspectionFromSchema.d.mts +54 -0
- package/utilities/introspectionFromSchema.d.ts +54 -0
- package/utilities/introspectionFromSchema.js +0 -9
- package/utilities/introspectionFromSchema.js.map +1 -1
- package/utilities/introspectionFromSchema.mjs +0 -9
- package/utilities/introspectionFromSchema.mjs.map +1 -1
- package/utilities/lexicographicSortSchema.d.mts +35 -0
- package/utilities/lexicographicSortSchema.d.ts +35 -0
- package/utilities/lexicographicSortSchema.js +0 -5
- package/utilities/lexicographicSortSchema.js.map +1 -1
- package/utilities/lexicographicSortSchema.mjs +0 -5
- package/utilities/lexicographicSortSchema.mjs.map +1 -1
- package/utilities/mapSchemaConfig.d.mts +6 -3
- package/utilities/mapSchemaConfig.d.ts +6 -3
- package/utilities/mapSchemaConfig.js +0 -10
- package/utilities/mapSchemaConfig.js.map +1 -1
- package/utilities/mapSchemaConfig.mjs +0 -10
- package/utilities/mapSchemaConfig.mjs.map +1 -1
- package/utilities/printSchema.d.mts +84 -0
- package/utilities/printSchema.d.ts +84 -0
- package/utilities/printSchema.js +0 -28
- package/utilities/printSchema.js.map +1 -1
- package/utilities/printSchema.mjs +0 -28
- package/utilities/printSchema.mjs.map +1 -1
- package/utilities/replaceVariables.d.mts +36 -0
- package/utilities/replaceVariables.d.ts +36 -0
- package/utilities/replaceVariables.js +0 -8
- package/utilities/replaceVariables.js.map +1 -1
- package/utilities/replaceVariables.mjs +0 -8
- package/utilities/replaceVariables.mjs.map +1 -1
- package/utilities/resolveSchemaCoordinate.d.mts +62 -0
- package/utilities/resolveSchemaCoordinate.d.ts +62 -0
- package/utilities/resolveSchemaCoordinate.js +0 -56
- package/utilities/resolveSchemaCoordinate.js.map +1 -1
- package/utilities/resolveSchemaCoordinate.mjs +0 -56
- package/utilities/resolveSchemaCoordinate.mjs.map +1 -1
- package/utilities/separateOperations.d.mts +30 -0
- package/utilities/separateOperations.d.ts +30 -0
- package/utilities/separateOperations.js +0 -15
- package/utilities/separateOperations.js.map +1 -1
- package/utilities/separateOperations.mjs +0 -15
- package/utilities/separateOperations.mjs.map +1 -1
- package/utilities/sortValueNode.js +0 -7
- package/utilities/sortValueNode.js.map +1 -1
- package/utilities/sortValueNode.mjs +0 -7
- package/utilities/sortValueNode.mjs.map +1 -1
- package/utilities/stripIgnoredCharacters.d.mts +13 -6
- package/utilities/stripIgnoredCharacters.d.ts +13 -6
- package/utilities/stripIgnoredCharacters.js +0 -65
- package/utilities/stripIgnoredCharacters.js.map +1 -1
- package/utilities/stripIgnoredCharacters.mjs +0 -65
- package/utilities/stripIgnoredCharacters.mjs.map +1 -1
- package/utilities/typeComparators.d.mts +84 -0
- package/utilities/typeComparators.d.ts +84 -0
- package/utilities/typeComparators.js +0 -33
- package/utilities/typeComparators.js.map +1 -1
- package/utilities/typeComparators.mjs +0 -33
- package/utilities/typeComparators.mjs.map +1 -1
- package/utilities/typeFromAST.d.mts +86 -0
- package/utilities/typeFromAST.d.ts +86 -0
- package/utilities/typeFromAST.js.map +1 -1
- package/utilities/typeFromAST.mjs.map +1 -1
- package/utilities/typedQueryDocumentNode.d.mts +4 -0
- package/utilities/typedQueryDocumentNode.d.ts +4 -0
- package/utilities/typedQueryDocumentNode.js.map +1 -1
- package/utilities/typedQueryDocumentNode.mjs.map +1 -1
- package/utilities/validateInputValue.d.mts +123 -0
- package/utilities/validateInputValue.d.ts +123 -0
- package/utilities/validateInputValue.js +0 -20
- package/utilities/validateInputValue.js.map +1 -1
- package/utilities/validateInputValue.mjs +0 -20
- package/utilities/validateInputValue.mjs.map +1 -1
- package/utilities/valueFromAST.d.mts +41 -0
- package/utilities/valueFromAST.d.ts +41 -0
- package/utilities/valueFromAST.js +13 -51
- package/utilities/valueFromAST.js.map +1 -1
- package/utilities/valueFromAST.mjs +13 -51
- package/utilities/valueFromAST.mjs.map +1 -1
- package/utilities/valueFromASTUntyped.d.mts +15 -2
- package/utilities/valueFromASTUntyped.d.ts +15 -2
- package/utilities/valueFromASTUntyped.js +0 -16
- package/utilities/valueFromASTUntyped.js.map +1 -1
- package/utilities/valueFromASTUntyped.mjs +0 -16
- package/utilities/valueFromASTUntyped.mjs.map +1 -1
- package/utilities/valueToLiteral.d.mts +30 -1
- package/utilities/valueToLiteral.d.ts +30 -1
- package/utilities/valueToLiteral.js +7 -40
- package/utilities/valueToLiteral.js.map +1 -1
- package/utilities/valueToLiteral.mjs +7 -40
- package/utilities/valueToLiteral.mjs.map +1 -1
- package/validation/ValidationContext.d.mts +490 -0
- package/validation/ValidationContext.d.ts +490 -0
- package/validation/ValidationContext.js +1 -8
- package/validation/ValidationContext.js.map +1 -1
- package/validation/ValidationContext.mjs +1 -8
- package/validation/ValidationContext.mjs.map +1 -1
- package/validation/index.d.mts +7 -0
- package/validation/index.d.ts +7 -0
- package/validation/index.js +0 -34
- package/validation/index.js.map +1 -1
- package/validation/index.mjs +0 -34
- package/validation/index.mjs.map +1 -1
- package/validation/rules/DeferStreamDirectiveLabelRule.d.mts +30 -0
- package/validation/rules/DeferStreamDirectiveLabelRule.d.ts +30 -0
- package/validation/rules/DeferStreamDirectiveLabelRule.js +0 -5
- package/validation/rules/DeferStreamDirectiveLabelRule.js.map +1 -1
- package/validation/rules/DeferStreamDirectiveLabelRule.mjs +0 -5
- package/validation/rules/DeferStreamDirectiveLabelRule.mjs.map +1 -1
- package/validation/rules/DeferStreamDirectiveOnRootFieldRule.d.mts +28 -0
- package/validation/rules/DeferStreamDirectiveOnRootFieldRule.d.ts +28 -0
- package/validation/rules/DeferStreamDirectiveOnRootFieldRule.js +0 -5
- package/validation/rules/DeferStreamDirectiveOnRootFieldRule.js.map +1 -1
- package/validation/rules/DeferStreamDirectiveOnRootFieldRule.mjs +0 -5
- package/validation/rules/DeferStreamDirectiveOnRootFieldRule.mjs.map +1 -1
- package/validation/rules/DeferStreamDirectiveOnValidOperationsRule.d.mts +52 -0
- package/validation/rules/DeferStreamDirectiveOnValidOperationsRule.d.ts +52 -0
- package/validation/rules/DeferStreamDirectiveOnValidOperationsRule.js +0 -5
- package/validation/rules/DeferStreamDirectiveOnValidOperationsRule.js.map +1 -1
- package/validation/rules/DeferStreamDirectiveOnValidOperationsRule.mjs +0 -5
- package/validation/rules/DeferStreamDirectiveOnValidOperationsRule.mjs.map +1 -1
- package/validation/rules/ExecutableDefinitionsRule.d.mts +28 -0
- package/validation/rules/ExecutableDefinitionsRule.d.ts +28 -0
- package/validation/rules/ExecutableDefinitionsRule.js +0 -8
- package/validation/rules/ExecutableDefinitionsRule.js.map +1 -1
- package/validation/rules/ExecutableDefinitionsRule.mjs +0 -8
- package/validation/rules/ExecutableDefinitionsRule.mjs.map +1 -1
- package/validation/rules/FieldsOnCorrectTypeRule.d.mts +28 -0
- package/validation/rules/FieldsOnCorrectTypeRule.d.ts +28 -0
- package/validation/rules/FieldsOnCorrectTypeRule.js +0 -27
- package/validation/rules/FieldsOnCorrectTypeRule.js.map +1 -1
- package/validation/rules/FieldsOnCorrectTypeRule.mjs +0 -27
- package/validation/rules/FieldsOnCorrectTypeRule.mjs.map +1 -1
- package/validation/rules/FragmentsOnCompositeTypesRule.d.mts +28 -0
- package/validation/rules/FragmentsOnCompositeTypesRule.d.ts +28 -0
- package/validation/rules/FragmentsOnCompositeTypesRule.js +0 -9
- package/validation/rules/FragmentsOnCompositeTypesRule.js.map +1 -1
- package/validation/rules/FragmentsOnCompositeTypesRule.mjs +0 -9
- package/validation/rules/FragmentsOnCompositeTypesRule.mjs.map +1 -1
- package/validation/rules/KnownArgumentNamesRule.d.mts +29 -3
- package/validation/rules/KnownArgumentNamesRule.d.ts +29 -3
- package/validation/rules/KnownArgumentNamesRule.js +0 -13
- package/validation/rules/KnownArgumentNamesRule.js.map +1 -1
- package/validation/rules/KnownArgumentNamesRule.mjs +0 -13
- package/validation/rules/KnownArgumentNamesRule.mjs.map +1 -1
- package/validation/rules/KnownDirectivesRule.d.mts +28 -0
- package/validation/rules/KnownDirectivesRule.d.ts +28 -0
- package/validation/rules/KnownDirectivesRule.js +0 -10
- package/validation/rules/KnownDirectivesRule.js.map +1 -1
- package/validation/rules/KnownDirectivesRule.mjs +0 -10
- package/validation/rules/KnownDirectivesRule.mjs.map +1 -1
- package/validation/rules/KnownFragmentNamesRule.d.mts +28 -0
- package/validation/rules/KnownFragmentNamesRule.d.ts +28 -0
- package/validation/rules/KnownFragmentNamesRule.js +0 -8
- package/validation/rules/KnownFragmentNamesRule.js.map +1 -1
- package/validation/rules/KnownFragmentNamesRule.mjs +0 -8
- package/validation/rules/KnownFragmentNamesRule.mjs.map +1 -1
- package/validation/rules/KnownOperationTypesRule.d.mts +20 -0
- package/validation/rules/KnownOperationTypesRule.d.ts +20 -0
- package/validation/rules/KnownOperationTypesRule.js +0 -8
- package/validation/rules/KnownOperationTypesRule.js.map +1 -1
- package/validation/rules/KnownOperationTypesRule.mjs +0 -8
- package/validation/rules/KnownOperationTypesRule.mjs.map +1 -1
- package/validation/rules/KnownTypeNamesRule.d.mts +28 -0
- package/validation/rules/KnownTypeNamesRule.d.ts +28 -0
- package/validation/rules/KnownTypeNamesRule.js +0 -8
- package/validation/rules/KnownTypeNamesRule.js.map +1 -1
- package/validation/rules/KnownTypeNamesRule.mjs +0 -8
- package/validation/rules/KnownTypeNamesRule.mjs.map +1 -1
- package/validation/rules/LoneAnonymousOperationRule.d.mts +28 -0
- package/validation/rules/LoneAnonymousOperationRule.d.ts +28 -0
- package/validation/rules/LoneAnonymousOperationRule.js +0 -8
- package/validation/rules/LoneAnonymousOperationRule.js.map +1 -1
- package/validation/rules/LoneAnonymousOperationRule.mjs +0 -8
- package/validation/rules/LoneAnonymousOperationRule.mjs.map +1 -1
- package/validation/rules/LoneSchemaDefinitionRule.d.mts +21 -0
- package/validation/rules/LoneSchemaDefinitionRule.d.ts +21 -0
- package/validation/rules/LoneSchemaDefinitionRule.js +0 -5
- package/validation/rules/LoneSchemaDefinitionRule.js.map +1 -1
- package/validation/rules/LoneSchemaDefinitionRule.mjs +0 -5
- package/validation/rules/LoneSchemaDefinitionRule.mjs.map +1 -1
- package/validation/rules/MaxIntrospectionDepthRule.d.mts +31 -0
- package/validation/rules/MaxIntrospectionDepthRule.d.ts +31 -0
- package/validation/rules/MaxIntrospectionDepthRule.js +0 -14
- package/validation/rules/MaxIntrospectionDepthRule.js.map +1 -1
- package/validation/rules/MaxIntrospectionDepthRule.mjs +0 -14
- package/validation/rules/MaxIntrospectionDepthRule.mjs.map +1 -1
- package/validation/rules/NoFragmentCyclesRule.d.mts +28 -0
- package/validation/rules/NoFragmentCyclesRule.d.ts +28 -0
- package/validation/rules/NoFragmentCyclesRule.js +0 -15
- package/validation/rules/NoFragmentCyclesRule.js.map +1 -1
- package/validation/rules/NoFragmentCyclesRule.mjs +0 -15
- package/validation/rules/NoFragmentCyclesRule.mjs.map +1 -1
- package/validation/rules/NoUndefinedVariablesRule.d.mts +28 -0
- package/validation/rules/NoUndefinedVariablesRule.d.ts +28 -0
- package/validation/rules/NoUndefinedVariablesRule.js +0 -8
- package/validation/rules/NoUndefinedVariablesRule.js.map +1 -1
- package/validation/rules/NoUndefinedVariablesRule.mjs +0 -8
- package/validation/rules/NoUndefinedVariablesRule.mjs.map +1 -1
- package/validation/rules/NoUnusedFragmentsRule.d.mts +28 -0
- package/validation/rules/NoUnusedFragmentsRule.d.ts +28 -0
- package/validation/rules/NoUnusedFragmentsRule.js +0 -8
- package/validation/rules/NoUnusedFragmentsRule.js.map +1 -1
- package/validation/rules/NoUnusedFragmentsRule.mjs +0 -8
- package/validation/rules/NoUnusedFragmentsRule.mjs.map +1 -1
- package/validation/rules/NoUnusedVariablesRule.d.mts +29 -0
- package/validation/rules/NoUnusedVariablesRule.d.ts +29 -0
- package/validation/rules/NoUnusedVariablesRule.js +0 -8
- package/validation/rules/NoUnusedVariablesRule.js.map +1 -1
- package/validation/rules/NoUnusedVariablesRule.mjs +0 -8
- package/validation/rules/NoUnusedVariablesRule.mjs.map +1 -1
- package/validation/rules/OverlappingFieldsCanBeMergedRule.d.mts +33 -0
- package/validation/rules/OverlappingFieldsCanBeMergedRule.d.ts +33 -0
- package/validation/rules/OverlappingFieldsCanBeMergedRule.js +1 -175
- package/validation/rules/OverlappingFieldsCanBeMergedRule.js.map +1 -1
- package/validation/rules/OverlappingFieldsCanBeMergedRule.mjs +1 -175
- package/validation/rules/OverlappingFieldsCanBeMergedRule.mjs.map +1 -1
- package/validation/rules/PossibleFragmentSpreadsRule.d.mts +36 -0
- package/validation/rules/PossibleFragmentSpreadsRule.d.ts +36 -0
- package/validation/rules/PossibleFragmentSpreadsRule.js +0 -7
- package/validation/rules/PossibleFragmentSpreadsRule.js.map +1 -1
- package/validation/rules/PossibleFragmentSpreadsRule.mjs +0 -7
- package/validation/rules/PossibleFragmentSpreadsRule.mjs.map +1 -1
- package/validation/rules/PossibleTypeExtensionsRule.d.mts +21 -0
- package/validation/rules/PossibleTypeExtensionsRule.d.ts +21 -0
- package/validation/rules/PossibleTypeExtensionsRule.js +0 -9
- package/validation/rules/PossibleTypeExtensionsRule.js.map +1 -1
- package/validation/rules/PossibleTypeExtensionsRule.mjs +0 -9
- package/validation/rules/PossibleTypeExtensionsRule.mjs.map +1 -1
- package/validation/rules/ProvidedRequiredArgumentsRule.d.mts +29 -3
- package/validation/rules/ProvidedRequiredArgumentsRule.d.ts +29 -3
- package/validation/rules/ProvidedRequiredArgumentsRule.js +0 -13
- package/validation/rules/ProvidedRequiredArgumentsRule.js.map +1 -1
- package/validation/rules/ProvidedRequiredArgumentsRule.mjs +0 -13
- package/validation/rules/ProvidedRequiredArgumentsRule.mjs.map +1 -1
- package/validation/rules/ScalarLeafsRule.d.mts +28 -0
- package/validation/rules/ScalarLeafsRule.d.ts +28 -0
- package/validation/rules/ScalarLeafsRule.js +0 -6
- package/validation/rules/ScalarLeafsRule.js.map +1 -1
- package/validation/rules/ScalarLeafsRule.mjs +0 -6
- package/validation/rules/ScalarLeafsRule.mjs.map +1 -1
- package/validation/rules/SingleFieldSubscriptionsRule.d.mts +34 -2
- package/validation/rules/SingleFieldSubscriptionsRule.d.ts +34 -2
- package/validation/rules/SingleFieldSubscriptionsRule.js +0 -9
- package/validation/rules/SingleFieldSubscriptionsRule.js.map +1 -1
- package/validation/rules/SingleFieldSubscriptionsRule.mjs +0 -9
- package/validation/rules/SingleFieldSubscriptionsRule.mjs.map +1 -1
- package/validation/rules/StreamDirectiveOnListFieldRule.d.mts +21 -0
- package/validation/rules/StreamDirectiveOnListFieldRule.d.ts +21 -0
- package/validation/rules/StreamDirectiveOnListFieldRule.js +0 -5
- package/validation/rules/StreamDirectiveOnListFieldRule.js.map +1 -1
- package/validation/rules/StreamDirectiveOnListFieldRule.mjs +0 -5
- package/validation/rules/StreamDirectiveOnListFieldRule.mjs.map +1 -1
- package/validation/rules/UniqueArgumentDefinitionNamesRule.d.mts +21 -0
- package/validation/rules/UniqueArgumentDefinitionNamesRule.d.ts +21 -0
- package/validation/rules/UniqueArgumentDefinitionNamesRule.js +0 -6
- package/validation/rules/UniqueArgumentDefinitionNamesRule.js.map +1 -1
- package/validation/rules/UniqueArgumentDefinitionNamesRule.mjs +0 -6
- package/validation/rules/UniqueArgumentDefinitionNamesRule.mjs.map +1 -1
- package/validation/rules/UniqueArgumentNamesRule.d.mts +28 -0
- package/validation/rules/UniqueArgumentNamesRule.d.ts +28 -0
- package/validation/rules/UniqueArgumentNamesRule.js +0 -8
- package/validation/rules/UniqueArgumentNamesRule.js.map +1 -1
- package/validation/rules/UniqueArgumentNamesRule.mjs +0 -8
- package/validation/rules/UniqueArgumentNamesRule.mjs.map +1 -1
- package/validation/rules/UniqueDirectiveNamesRule.d.mts +21 -0
- package/validation/rules/UniqueDirectiveNamesRule.d.ts +21 -0
- package/validation/rules/UniqueDirectiveNamesRule.js +0 -5
- package/validation/rules/UniqueDirectiveNamesRule.js.map +1 -1
- package/validation/rules/UniqueDirectiveNamesRule.mjs +0 -5
- package/validation/rules/UniqueDirectiveNamesRule.mjs.map +1 -1
- package/validation/rules/UniqueDirectivesPerLocationRule.d.mts +28 -0
- package/validation/rules/UniqueDirectivesPerLocationRule.d.ts +28 -0
- package/validation/rules/UniqueDirectivesPerLocationRule.js +0 -11
- package/validation/rules/UniqueDirectivesPerLocationRule.js.map +1 -1
- package/validation/rules/UniqueDirectivesPerLocationRule.mjs +0 -11
- package/validation/rules/UniqueDirectivesPerLocationRule.mjs.map +1 -1
- package/validation/rules/UniqueEnumValueNamesRule.d.mts +21 -0
- package/validation/rules/UniqueEnumValueNamesRule.d.ts +21 -0
- package/validation/rules/UniqueEnumValueNamesRule.js +0 -5
- package/validation/rules/UniqueEnumValueNamesRule.js.map +1 -1
- package/validation/rules/UniqueEnumValueNamesRule.mjs +0 -5
- package/validation/rules/UniqueEnumValueNamesRule.mjs.map +1 -1
- package/validation/rules/UniqueFieldDefinitionNamesRule.d.mts +21 -0
- package/validation/rules/UniqueFieldDefinitionNamesRule.d.ts +21 -0
- package/validation/rules/UniqueFieldDefinitionNamesRule.js +0 -5
- package/validation/rules/UniqueFieldDefinitionNamesRule.js.map +1 -1
- package/validation/rules/UniqueFieldDefinitionNamesRule.mjs +0 -5
- package/validation/rules/UniqueFieldDefinitionNamesRule.mjs.map +1 -1
- package/validation/rules/UniqueFragmentNamesRule.d.mts +28 -0
- package/validation/rules/UniqueFragmentNamesRule.d.ts +28 -0
- package/validation/rules/UniqueFragmentNamesRule.js +0 -7
- package/validation/rules/UniqueFragmentNamesRule.js.map +1 -1
- package/validation/rules/UniqueFragmentNamesRule.mjs +0 -7
- package/validation/rules/UniqueFragmentNamesRule.mjs.map +1 -1
- package/validation/rules/UniqueInputFieldNamesRule.d.mts +32 -0
- package/validation/rules/UniqueInputFieldNamesRule.d.ts +32 -0
- package/validation/rules/UniqueInputFieldNamesRule.js +0 -8
- package/validation/rules/UniqueInputFieldNamesRule.js.map +1 -1
- package/validation/rules/UniqueInputFieldNamesRule.mjs +0 -8
- package/validation/rules/UniqueInputFieldNamesRule.mjs.map +1 -1
- package/validation/rules/UniqueOperationNamesRule.d.mts +28 -0
- package/validation/rules/UniqueOperationNamesRule.d.ts +28 -0
- package/validation/rules/UniqueOperationNamesRule.js +0 -7
- package/validation/rules/UniqueOperationNamesRule.js.map +1 -1
- package/validation/rules/UniqueOperationNamesRule.mjs +0 -7
- package/validation/rules/UniqueOperationNamesRule.mjs.map +1 -1
- package/validation/rules/UniqueOperationTypesRule.d.mts +21 -0
- package/validation/rules/UniqueOperationTypesRule.d.ts +21 -0
- package/validation/rules/UniqueOperationTypesRule.js +0 -5
- package/validation/rules/UniqueOperationTypesRule.js.map +1 -1
- package/validation/rules/UniqueOperationTypesRule.mjs +0 -5
- package/validation/rules/UniqueOperationTypesRule.mjs.map +1 -1
- package/validation/rules/UniqueTypeNamesRule.d.mts +21 -0
- package/validation/rules/UniqueTypeNamesRule.d.ts +21 -0
- package/validation/rules/UniqueTypeNamesRule.js +0 -5
- package/validation/rules/UniqueTypeNamesRule.js.map +1 -1
- package/validation/rules/UniqueTypeNamesRule.mjs +0 -5
- package/validation/rules/UniqueTypeNamesRule.mjs.map +1 -1
- package/validation/rules/UniqueVariableNamesRule.d.mts +28 -0
- package/validation/rules/UniqueVariableNamesRule.d.ts +28 -0
- package/validation/rules/UniqueVariableNamesRule.js +0 -5
- package/validation/rules/UniqueVariableNamesRule.js.map +1 -1
- package/validation/rules/UniqueVariableNamesRule.mjs +0 -5
- package/validation/rules/UniqueVariableNamesRule.mjs.map +1 -1
- package/validation/rules/ValuesOfCorrectTypeRule.d.mts +28 -0
- package/validation/rules/ValuesOfCorrectTypeRule.d.ts +28 -0
- package/validation/rules/ValuesOfCorrectTypeRule.js +1 -21
- package/validation/rules/ValuesOfCorrectTypeRule.js.map +1 -1
- package/validation/rules/ValuesOfCorrectTypeRule.mjs +1 -21
- package/validation/rules/ValuesOfCorrectTypeRule.mjs.map +1 -1
- package/validation/rules/VariablesAreInputTypesRule.d.mts +32 -0
- package/validation/rules/VariablesAreInputTypesRule.d.ts +32 -0
- package/validation/rules/VariablesAreInputTypesRule.js +0 -8
- package/validation/rules/VariablesAreInputTypesRule.js.map +1 -1
- package/validation/rules/VariablesAreInputTypesRule.mjs +0 -8
- package/validation/rules/VariablesAreInputTypesRule.mjs.map +1 -1
- package/validation/rules/VariablesInAllowedPositionRule.d.mts +28 -0
- package/validation/rules/VariablesInAllowedPositionRule.d.ts +28 -0
- package/validation/rules/VariablesInAllowedPositionRule.js +0 -20
- package/validation/rules/VariablesInAllowedPositionRule.js.map +1 -1
- package/validation/rules/VariablesInAllowedPositionRule.mjs +0 -20
- package/validation/rules/VariablesInAllowedPositionRule.mjs.map +1 -1
- package/validation/rules/custom/NoDeprecatedCustomRule.d.mts +41 -0
- package/validation/rules/custom/NoDeprecatedCustomRule.d.ts +41 -0
- package/validation/rules/custom/NoDeprecatedCustomRule.js +0 -10
- package/validation/rules/custom/NoDeprecatedCustomRule.js.map +1 -1
- package/validation/rules/custom/NoDeprecatedCustomRule.mjs +0 -10
- package/validation/rules/custom/NoDeprecatedCustomRule.mjs.map +1 -1
- package/validation/rules/custom/NoSchemaIntrospectionCustomRule.d.mts +28 -0
- package/validation/rules/custom/NoSchemaIntrospectionCustomRule.d.ts +28 -0
- package/validation/rules/custom/NoSchemaIntrospectionCustomRule.js +0 -10
- package/validation/rules/custom/NoSchemaIntrospectionCustomRule.js.map +1 -1
- package/validation/rules/custom/NoSchemaIntrospectionCustomRule.mjs +0 -10
- package/validation/rules/custom/NoSchemaIntrospectionCustomRule.mjs.map +1 -1
- package/validation/specifiedRules.d.mts +2 -3
- package/validation/specifiedRules.d.ts +2 -3
- package/validation/specifiedRules.js +0 -46
- package/validation/specifiedRules.js.map +1 -1
- package/validation/specifiedRules.mjs +0 -46
- package/validation/specifiedRules.mjs.map +1 -1
- package/validation/validate.d.mts +65 -7
- package/validation/validate.d.ts +65 -7
- package/validation/validate.js +0 -41
- package/validation/validate.js.map +1 -1
- package/validation/validate.mjs +0 -41
- package/validation/validate.mjs.map +1 -1
- package/version.d.mts +3 -6
- package/version.d.ts +3 -6
- package/version.js +2 -10
- package/version.js.map +1 -1
- package/version.mjs +2 -10
- package/version.mjs.map +1 -1
package/language/parser.mjs
CHANGED
|
@@ -6,10 +6,6 @@ import { isPunctuatorTokenKind, Lexer } from "./lexer.mjs";
|
|
|
6
6
|
import { SchemaCoordinateLexer } from "./schemaCoordinateLexer.mjs";
|
|
7
7
|
import { isSource, Source } from "./source.mjs";
|
|
8
8
|
import { TokenKind } from "./tokenKind.mjs";
|
|
9
|
-
/**
|
|
10
|
-
* Given a GraphQL source, parses it into a Document.
|
|
11
|
-
* Throws GraphQLError if a syntax error is encountered.
|
|
12
|
-
*/
|
|
13
9
|
export function parse(source, options) {
|
|
14
10
|
const parser = new Parser(source, options);
|
|
15
11
|
const document = parser.parseDocument();
|
|
@@ -19,14 +15,6 @@ export function parse(source, options) {
|
|
|
19
15
|
});
|
|
20
16
|
return document;
|
|
21
17
|
}
|
|
22
|
-
/**
|
|
23
|
-
* Given a string containing a GraphQL value (ex. `[42]`), parse the AST for
|
|
24
|
-
* that value.
|
|
25
|
-
* Throws GraphQLError if a syntax error is encountered.
|
|
26
|
-
*
|
|
27
|
-
* This is useful within tools that operate upon GraphQL Values directly and
|
|
28
|
-
* in isolation of complete GraphQL documents.
|
|
29
|
-
*/
|
|
30
18
|
export function parseValue(source, options) {
|
|
31
19
|
const parser = new Parser(source, options);
|
|
32
20
|
parser.expectToken(TokenKind.SOF);
|
|
@@ -34,10 +22,6 @@ export function parseValue(source, options) {
|
|
|
34
22
|
parser.expectToken(TokenKind.EOF);
|
|
35
23
|
return value;
|
|
36
24
|
}
|
|
37
|
-
/**
|
|
38
|
-
* Similar to parseValue(), but raises a parse error if it encounters a
|
|
39
|
-
* variable. The return type will be a constant value.
|
|
40
|
-
*/
|
|
41
25
|
export function parseConstValue(source, options) {
|
|
42
26
|
const parser = new Parser(source, options);
|
|
43
27
|
parser.expectToken(TokenKind.SOF);
|
|
@@ -45,16 +29,6 @@ export function parseConstValue(source, options) {
|
|
|
45
29
|
parser.expectToken(TokenKind.EOF);
|
|
46
30
|
return value;
|
|
47
31
|
}
|
|
48
|
-
/**
|
|
49
|
-
* Given a string containing a GraphQL Type (ex. `[Int!]`), parse the AST for
|
|
50
|
-
* that type.
|
|
51
|
-
* Throws GraphQLError if a syntax error is encountered.
|
|
52
|
-
*
|
|
53
|
-
* This is useful within tools that operate upon GraphQL Types directly and
|
|
54
|
-
* in isolation of complete GraphQL documents.
|
|
55
|
-
*
|
|
56
|
-
* Consider providing the results to the utility function: typeFromAST().
|
|
57
|
-
*/
|
|
58
32
|
export function parseType(source, options) {
|
|
59
33
|
const parser = new Parser(source, options);
|
|
60
34
|
parser.expectToken(TokenKind.SOF);
|
|
@@ -62,15 +36,6 @@ export function parseType(source, options) {
|
|
|
62
36
|
parser.expectToken(TokenKind.EOF);
|
|
63
37
|
return type;
|
|
64
38
|
}
|
|
65
|
-
/**
|
|
66
|
-
* Given a string containing a GraphQL Schema Coordinate (ex. `Type.field`),
|
|
67
|
-
* parse the AST for that schema coordinate.
|
|
68
|
-
* Throws GraphQLError if a syntax error is encountered.
|
|
69
|
-
*
|
|
70
|
-
* Consider providing the results to the utility function:
|
|
71
|
-
* resolveASTSchemaCoordinate(). Or calling resolveSchemaCoordinate() directly
|
|
72
|
-
* with an unparsed source.
|
|
73
|
-
*/
|
|
74
39
|
export function parseSchemaCoordinate(source) {
|
|
75
40
|
const sourceObj = isSource(source) ? source : new Source(source);
|
|
76
41
|
const lexer = new SchemaCoordinateLexer(sourceObj);
|
|
@@ -80,17 +45,6 @@ export function parseSchemaCoordinate(source) {
|
|
|
80
45
|
parser.expectToken(TokenKind.EOF);
|
|
81
46
|
return coordinate;
|
|
82
47
|
}
|
|
83
|
-
/**
|
|
84
|
-
* This class is exported only to assist people in implementing their own parsers
|
|
85
|
-
* without duplicating too much code and should be used only as last resort for cases
|
|
86
|
-
* such as experimental syntax or if certain features could not be contributed upstream.
|
|
87
|
-
*
|
|
88
|
-
* It is still part of the internal API and is versioned, so any changes to it are never
|
|
89
|
-
* considered breaking changes. If you still need to support multiple versions of the
|
|
90
|
-
* library, please use the `versionInfo` variable for version detection.
|
|
91
|
-
*
|
|
92
|
-
* @internal
|
|
93
|
-
*/
|
|
94
48
|
export class Parser {
|
|
95
49
|
constructor(source, options = {}) {
|
|
96
50
|
const { lexer, ..._options } = options;
|
|
@@ -107,9 +61,6 @@ export class Parser {
|
|
|
107
61
|
get tokenCount() {
|
|
108
62
|
return this._tokenCounter;
|
|
109
63
|
}
|
|
110
|
-
/**
|
|
111
|
-
* Converts a name lex token into a name parse node.
|
|
112
|
-
*/
|
|
113
64
|
parseName() {
|
|
114
65
|
const token = this.expectToken(TokenKind.NAME);
|
|
115
66
|
return this.node(token, {
|
|
@@ -117,44 +68,16 @@ export class Parser {
|
|
|
117
68
|
value: token.value,
|
|
118
69
|
});
|
|
119
70
|
}
|
|
120
|
-
// Implements the parsing rules in the Document section.
|
|
121
|
-
/**
|
|
122
|
-
* Document : Definition+
|
|
123
|
-
*/
|
|
124
71
|
parseDocument() {
|
|
125
72
|
return this.node(this._lexer.token, {
|
|
126
73
|
kind: Kind.DOCUMENT,
|
|
127
74
|
definitions: this.many(TokenKind.SOF, this.parseDefinition, TokenKind.EOF),
|
|
128
75
|
});
|
|
129
76
|
}
|
|
130
|
-
/**
|
|
131
|
-
* Definition :
|
|
132
|
-
* - ExecutableDefinition
|
|
133
|
-
* - TypeSystemDefinition
|
|
134
|
-
* - TypeSystemExtension
|
|
135
|
-
*
|
|
136
|
-
* ExecutableDefinition :
|
|
137
|
-
* - OperationDefinition
|
|
138
|
-
* - FragmentDefinition
|
|
139
|
-
*
|
|
140
|
-
* TypeSystemDefinition :
|
|
141
|
-
* - SchemaDefinition
|
|
142
|
-
* - TypeDefinition
|
|
143
|
-
* - DirectiveDefinition
|
|
144
|
-
*
|
|
145
|
-
* TypeDefinition :
|
|
146
|
-
* - ScalarTypeDefinition
|
|
147
|
-
* - ObjectTypeDefinition
|
|
148
|
-
* - InterfaceTypeDefinition
|
|
149
|
-
* - UnionTypeDefinition
|
|
150
|
-
* - EnumTypeDefinition
|
|
151
|
-
* - InputObjectTypeDefinition
|
|
152
|
-
*/
|
|
153
77
|
parseDefinition() {
|
|
154
78
|
if (this.peek(TokenKind.BRACE_L)) {
|
|
155
79
|
return this.parseOperationDefinition();
|
|
156
80
|
}
|
|
157
|
-
// Many definitions begin with a description and require a lookahead.
|
|
158
81
|
const hasDescription = this.peekDescription();
|
|
159
82
|
const keywordToken = hasDescription
|
|
160
83
|
? this._lexer.lookahead()
|
|
@@ -199,12 +122,6 @@ export class Parser {
|
|
|
199
122
|
}
|
|
200
123
|
throw this.unexpected(keywordToken);
|
|
201
124
|
}
|
|
202
|
-
// Implements the parsing rules in the Operations section.
|
|
203
|
-
/**
|
|
204
|
-
* OperationDefinition :
|
|
205
|
-
* - SelectionSet
|
|
206
|
-
* - OperationType Name? VariableDefinitions? Directives? SelectionSet
|
|
207
|
-
*/
|
|
208
125
|
parseOperationDefinition() {
|
|
209
126
|
const start = this._lexer.token;
|
|
210
127
|
if (this.peek(TokenKind.BRACE_L)) {
|
|
@@ -234,9 +151,6 @@ export class Parser {
|
|
|
234
151
|
selectionSet: this.parseSelectionSet(),
|
|
235
152
|
});
|
|
236
153
|
}
|
|
237
|
-
/**
|
|
238
|
-
* OperationType : one of query mutation subscription
|
|
239
|
-
*/
|
|
240
154
|
parseOperationType() {
|
|
241
155
|
const operationToken = this.expectToken(TokenKind.NAME);
|
|
242
156
|
switch (operationToken.value) {
|
|
@@ -249,15 +163,9 @@ export class Parser {
|
|
|
249
163
|
}
|
|
250
164
|
throw this.unexpected(operationToken);
|
|
251
165
|
}
|
|
252
|
-
/**
|
|
253
|
-
* VariableDefinitions : ( VariableDefinition+ )
|
|
254
|
-
*/
|
|
255
166
|
parseVariableDefinitions() {
|
|
256
167
|
return this.optionalMany(TokenKind.PAREN_L, this.parseVariableDefinition, TokenKind.PAREN_R);
|
|
257
168
|
}
|
|
258
|
-
/**
|
|
259
|
-
* VariableDefinition : Variable : Type DefaultValue? Directives[Const]?
|
|
260
|
-
*/
|
|
261
169
|
parseVariableDefinition() {
|
|
262
170
|
return this.node(this._lexer.token, {
|
|
263
171
|
kind: Kind.VARIABLE_DEFINITION,
|
|
@@ -270,9 +178,6 @@ export class Parser {
|
|
|
270
178
|
directives: this.parseConstDirectives(),
|
|
271
179
|
});
|
|
272
180
|
}
|
|
273
|
-
/**
|
|
274
|
-
* Variable : $ Name
|
|
275
|
-
*/
|
|
276
181
|
parseVariable() {
|
|
277
182
|
const start = this._lexer.token;
|
|
278
183
|
this.expectToken(TokenKind.DOLLAR);
|
|
@@ -281,33 +186,17 @@ export class Parser {
|
|
|
281
186
|
name: this.parseName(),
|
|
282
187
|
});
|
|
283
188
|
}
|
|
284
|
-
/**
|
|
285
|
-
* ```
|
|
286
|
-
* SelectionSet : { Selection+ }
|
|
287
|
-
* ```
|
|
288
|
-
*/
|
|
289
189
|
parseSelectionSet() {
|
|
290
190
|
return this.node(this._lexer.token, {
|
|
291
191
|
kind: Kind.SELECTION_SET,
|
|
292
192
|
selections: this.many(TokenKind.BRACE_L, this.parseSelection, TokenKind.BRACE_R),
|
|
293
193
|
});
|
|
294
194
|
}
|
|
295
|
-
/**
|
|
296
|
-
* Selection :
|
|
297
|
-
* - Field
|
|
298
|
-
* - FragmentSpread
|
|
299
|
-
* - InlineFragment
|
|
300
|
-
*/
|
|
301
195
|
parseSelection() {
|
|
302
196
|
return this.peek(TokenKind.SPREAD)
|
|
303
197
|
? this.parseFragment()
|
|
304
198
|
: this.parseField();
|
|
305
199
|
}
|
|
306
|
-
/**
|
|
307
|
-
* Field : Alias? Name Arguments? Directives? SelectionSet?
|
|
308
|
-
*
|
|
309
|
-
* Alias : Name :
|
|
310
|
-
*/
|
|
311
200
|
parseField() {
|
|
312
201
|
const start = this._lexer.token;
|
|
313
202
|
const nameOrAlias = this.parseName();
|
|
@@ -335,7 +224,6 @@ export class Parser {
|
|
|
335
224
|
const item = isConst ? this.parseConstArgument : this.parseArgument;
|
|
336
225
|
return this.optionalMany(TokenKind.PAREN_L, item, TokenKind.PAREN_R);
|
|
337
226
|
}
|
|
338
|
-
/* experimental */
|
|
339
227
|
parseFragmentArguments() {
|
|
340
228
|
const item = this.parseFragmentArgument;
|
|
341
229
|
return this.optionalMany(TokenKind.PAREN_L, item, TokenKind.PAREN_R);
|
|
@@ -353,7 +241,6 @@ export class Parser {
|
|
|
353
241
|
parseConstArgument() {
|
|
354
242
|
return this.parseArgument(true);
|
|
355
243
|
}
|
|
356
|
-
/* experimental */
|
|
357
244
|
parseFragmentArgument() {
|
|
358
245
|
const start = this._lexer.token;
|
|
359
246
|
const name = this.parseName();
|
|
@@ -364,14 +251,6 @@ export class Parser {
|
|
|
364
251
|
value: this.parseValueLiteral(false),
|
|
365
252
|
});
|
|
366
253
|
}
|
|
367
|
-
// Implements the parsing rules in the Fragments section.
|
|
368
|
-
/**
|
|
369
|
-
* Corresponds to both FragmentSpread and InlineFragment in the spec.
|
|
370
|
-
*
|
|
371
|
-
* FragmentSpread : ... FragmentName Arguments? Directives?
|
|
372
|
-
*
|
|
373
|
-
* InlineFragment : ... TypeCondition? Directives? SelectionSet
|
|
374
|
-
*/
|
|
375
254
|
parseFragment() {
|
|
376
255
|
const start = this._lexer.token;
|
|
377
256
|
this.expectToken(TokenKind.SPREAD);
|
|
@@ -400,12 +279,6 @@ export class Parser {
|
|
|
400
279
|
selectionSet: this.parseSelectionSet(),
|
|
401
280
|
});
|
|
402
281
|
}
|
|
403
|
-
/**
|
|
404
|
-
* FragmentDefinition :
|
|
405
|
-
* - fragment FragmentName VariableDefinitions? on TypeCondition Directives? SelectionSet
|
|
406
|
-
*
|
|
407
|
-
* TypeCondition : NamedType
|
|
408
|
-
*/
|
|
409
282
|
parseFragmentDefinition() {
|
|
410
283
|
const start = this._lexer.token;
|
|
411
284
|
const description = this.parseDescription();
|
|
@@ -430,9 +303,6 @@ export class Parser {
|
|
|
430
303
|
selectionSet: this.parseSelectionSet(),
|
|
431
304
|
});
|
|
432
305
|
}
|
|
433
|
-
/**
|
|
434
|
-
* FragmentName : Name but not `on`
|
|
435
|
-
*/
|
|
436
306
|
parseFragmentName() {
|
|
437
307
|
if (this._lexer.token.value === 'on') {
|
|
438
308
|
throw this.unexpected();
|
|
@@ -556,13 +426,6 @@ export class Parser {
|
|
|
556
426
|
arguments: this.parseArguments(isConst),
|
|
557
427
|
});
|
|
558
428
|
}
|
|
559
|
-
// Implements the parsing rules in the Types section.
|
|
560
|
-
/**
|
|
561
|
-
* Type :
|
|
562
|
-
* - NamedType
|
|
563
|
-
* - ListType
|
|
564
|
-
* - NonNullType
|
|
565
|
-
*/
|
|
566
429
|
parseTypeReference() {
|
|
567
430
|
const start = this._lexer.token;
|
|
568
431
|
let type;
|
|
@@ -585,32 +448,20 @@ export class Parser {
|
|
|
585
448
|
}
|
|
586
449
|
return type;
|
|
587
450
|
}
|
|
588
|
-
/**
|
|
589
|
-
* NamedType : Name
|
|
590
|
-
*/
|
|
591
451
|
parseNamedType() {
|
|
592
452
|
return this.node(this._lexer.token, {
|
|
593
453
|
kind: Kind.NAMED_TYPE,
|
|
594
454
|
name: this.parseName(),
|
|
595
455
|
});
|
|
596
456
|
}
|
|
597
|
-
// Implements the parsing rules in the Type Definition section.
|
|
598
457
|
peekDescription() {
|
|
599
458
|
return this.peek(TokenKind.STRING) || this.peek(TokenKind.BLOCK_STRING);
|
|
600
459
|
}
|
|
601
|
-
/**
|
|
602
|
-
* Description : StringValue
|
|
603
|
-
*/
|
|
604
460
|
parseDescription() {
|
|
605
461
|
if (this.peekDescription()) {
|
|
606
462
|
return this.parseStringLiteral();
|
|
607
463
|
}
|
|
608
464
|
}
|
|
609
|
-
/**
|
|
610
|
-
* ```
|
|
611
|
-
* SchemaDefinition : Description? schema Directives[Const]? { OperationTypeDefinition+ }
|
|
612
|
-
* ```
|
|
613
|
-
*/
|
|
614
465
|
parseSchemaDefinition() {
|
|
615
466
|
const start = this._lexer.token;
|
|
616
467
|
const description = this.parseDescription();
|
|
@@ -624,9 +475,6 @@ export class Parser {
|
|
|
624
475
|
operationTypes,
|
|
625
476
|
});
|
|
626
477
|
}
|
|
627
|
-
/**
|
|
628
|
-
* OperationTypeDefinition : OperationType : NamedType
|
|
629
|
-
*/
|
|
630
478
|
parseOperationTypeDefinition() {
|
|
631
479
|
const start = this._lexer.token;
|
|
632
480
|
const operation = this.parseOperationType();
|
|
@@ -638,9 +486,6 @@ export class Parser {
|
|
|
638
486
|
type,
|
|
639
487
|
});
|
|
640
488
|
}
|
|
641
|
-
/**
|
|
642
|
-
* ScalarTypeDefinition : Description? scalar Name Directives[Const]?
|
|
643
|
-
*/
|
|
644
489
|
parseScalarTypeDefinition() {
|
|
645
490
|
const start = this._lexer.token;
|
|
646
491
|
const description = this.parseDescription();
|
|
@@ -654,11 +499,6 @@ export class Parser {
|
|
|
654
499
|
directives,
|
|
655
500
|
});
|
|
656
501
|
}
|
|
657
|
-
/**
|
|
658
|
-
* ObjectTypeDefinition :
|
|
659
|
-
* Description?
|
|
660
|
-
* type Name ImplementsInterfaces? Directives[Const]? FieldsDefinition?
|
|
661
|
-
*/
|
|
662
502
|
parseObjectTypeDefinition() {
|
|
663
503
|
const start = this._lexer.token;
|
|
664
504
|
const description = this.parseDescription();
|
|
@@ -676,28 +516,14 @@ export class Parser {
|
|
|
676
516
|
fields,
|
|
677
517
|
});
|
|
678
518
|
}
|
|
679
|
-
/**
|
|
680
|
-
* ImplementsInterfaces :
|
|
681
|
-
* - implements `&`? NamedType
|
|
682
|
-
* - ImplementsInterfaces & NamedType
|
|
683
|
-
*/
|
|
684
519
|
parseImplementsInterfaces() {
|
|
685
520
|
return this.expectOptionalKeyword('implements')
|
|
686
521
|
? this.delimitedMany(TokenKind.AMP, this.parseNamedType)
|
|
687
522
|
: undefined;
|
|
688
523
|
}
|
|
689
|
-
/**
|
|
690
|
-
* ```
|
|
691
|
-
* FieldsDefinition : { FieldDefinition+ }
|
|
692
|
-
* ```
|
|
693
|
-
*/
|
|
694
524
|
parseFieldsDefinition() {
|
|
695
525
|
return this.optionalMany(TokenKind.BRACE_L, this.parseFieldDefinition, TokenKind.BRACE_R);
|
|
696
526
|
}
|
|
697
|
-
/**
|
|
698
|
-
* FieldDefinition :
|
|
699
|
-
* - Description? Name ArgumentsDefinition? : Type Directives[Const]?
|
|
700
|
-
*/
|
|
701
527
|
parseFieldDefinition() {
|
|
702
528
|
const start = this._lexer.token;
|
|
703
529
|
const description = this.parseDescription();
|
|
@@ -715,16 +541,9 @@ export class Parser {
|
|
|
715
541
|
directives,
|
|
716
542
|
});
|
|
717
543
|
}
|
|
718
|
-
/**
|
|
719
|
-
* ArgumentsDefinition : ( InputValueDefinition+ )
|
|
720
|
-
*/
|
|
721
544
|
parseArgumentDefs() {
|
|
722
545
|
return this.optionalMany(TokenKind.PAREN_L, this.parseInputValueDef, TokenKind.PAREN_R);
|
|
723
546
|
}
|
|
724
|
-
/**
|
|
725
|
-
* InputValueDefinition :
|
|
726
|
-
* - Description? Name : Type DefaultValue? Directives[Const]?
|
|
727
|
-
*/
|
|
728
547
|
parseInputValueDef() {
|
|
729
548
|
const start = this._lexer.token;
|
|
730
549
|
const description = this.parseDescription();
|
|
@@ -745,10 +564,6 @@ export class Parser {
|
|
|
745
564
|
directives,
|
|
746
565
|
});
|
|
747
566
|
}
|
|
748
|
-
/**
|
|
749
|
-
* InterfaceTypeDefinition :
|
|
750
|
-
* - Description? interface Name Directives[Const]? FieldsDefinition?
|
|
751
|
-
*/
|
|
752
567
|
parseInterfaceTypeDefinition() {
|
|
753
568
|
const start = this._lexer.token;
|
|
754
569
|
const description = this.parseDescription();
|
|
@@ -766,10 +581,6 @@ export class Parser {
|
|
|
766
581
|
fields,
|
|
767
582
|
});
|
|
768
583
|
}
|
|
769
|
-
/**
|
|
770
|
-
* UnionTypeDefinition :
|
|
771
|
-
* - Description? union Name Directives[Const]? UnionMemberTypes?
|
|
772
|
-
*/
|
|
773
584
|
parseUnionTypeDefinition() {
|
|
774
585
|
const start = this._lexer.token;
|
|
775
586
|
const description = this.parseDescription();
|
|
@@ -785,20 +596,11 @@ export class Parser {
|
|
|
785
596
|
types,
|
|
786
597
|
});
|
|
787
598
|
}
|
|
788
|
-
/**
|
|
789
|
-
* UnionMemberTypes :
|
|
790
|
-
* - = `|`? NamedType
|
|
791
|
-
* - UnionMemberTypes | NamedType
|
|
792
|
-
*/
|
|
793
599
|
parseUnionMemberTypes() {
|
|
794
600
|
return this.expectOptionalToken(TokenKind.EQUALS)
|
|
795
601
|
? this.delimitedMany(TokenKind.PIPE, this.parseNamedType)
|
|
796
602
|
: undefined;
|
|
797
603
|
}
|
|
798
|
-
/**
|
|
799
|
-
* EnumTypeDefinition :
|
|
800
|
-
* - Description? enum Name Directives[Const]? EnumValuesDefinition?
|
|
801
|
-
*/
|
|
802
604
|
parseEnumTypeDefinition() {
|
|
803
605
|
const start = this._lexer.token;
|
|
804
606
|
const description = this.parseDescription();
|
|
@@ -814,17 +616,9 @@ export class Parser {
|
|
|
814
616
|
values,
|
|
815
617
|
});
|
|
816
618
|
}
|
|
817
|
-
/**
|
|
818
|
-
* ```
|
|
819
|
-
* EnumValuesDefinition : { EnumValueDefinition+ }
|
|
820
|
-
* ```
|
|
821
|
-
*/
|
|
822
619
|
parseEnumValuesDefinition() {
|
|
823
620
|
return this.optionalMany(TokenKind.BRACE_L, this.parseEnumValueDefinition, TokenKind.BRACE_R);
|
|
824
621
|
}
|
|
825
|
-
/**
|
|
826
|
-
* EnumValueDefinition : Description? EnumValue Directives[Const]?
|
|
827
|
-
*/
|
|
828
622
|
parseEnumValueDefinition() {
|
|
829
623
|
const start = this._lexer.token;
|
|
830
624
|
const description = this.parseDescription();
|
|
@@ -837,9 +631,6 @@ export class Parser {
|
|
|
837
631
|
directives,
|
|
838
632
|
});
|
|
839
633
|
}
|
|
840
|
-
/**
|
|
841
|
-
* EnumValue : Name but not `true`, `false` or `null`
|
|
842
|
-
*/
|
|
843
634
|
parseEnumValueName() {
|
|
844
635
|
if (this._lexer.token.value === 'true' ||
|
|
845
636
|
this._lexer.token.value === 'false' ||
|
|
@@ -848,10 +639,6 @@ export class Parser {
|
|
|
848
639
|
}
|
|
849
640
|
return this.parseName();
|
|
850
641
|
}
|
|
851
|
-
/**
|
|
852
|
-
* InputObjectTypeDefinition :
|
|
853
|
-
* - Description? input Name Directives[Const]? InputFieldsDefinition?
|
|
854
|
-
*/
|
|
855
642
|
parseInputObjectTypeDefinition() {
|
|
856
643
|
const start = this._lexer.token;
|
|
857
644
|
const description = this.parseDescription();
|
|
@@ -867,28 +654,9 @@ export class Parser {
|
|
|
867
654
|
fields,
|
|
868
655
|
});
|
|
869
656
|
}
|
|
870
|
-
/**
|
|
871
|
-
* ```
|
|
872
|
-
* InputFieldsDefinition : { InputValueDefinition+ }
|
|
873
|
-
* ```
|
|
874
|
-
*/
|
|
875
657
|
parseInputFieldsDefinition() {
|
|
876
658
|
return this.optionalMany(TokenKind.BRACE_L, this.parseInputValueDef, TokenKind.BRACE_R);
|
|
877
659
|
}
|
|
878
|
-
/**
|
|
879
|
-
* TypeSystemExtension :
|
|
880
|
-
* - SchemaExtension
|
|
881
|
-
* - TypeExtension
|
|
882
|
-
*
|
|
883
|
-
* TypeExtension :
|
|
884
|
-
* - ScalarTypeExtension
|
|
885
|
-
* - ObjectTypeExtension
|
|
886
|
-
* - InterfaceTypeExtension
|
|
887
|
-
* - UnionTypeExtension
|
|
888
|
-
* - EnumTypeExtension
|
|
889
|
-
* - InputObjectTypeDefinition
|
|
890
|
-
* - DirectiveDefinitionExtension
|
|
891
|
-
*/
|
|
892
660
|
parseTypeSystemExtension() {
|
|
893
661
|
const keywordToken = this._lexer.lookahead();
|
|
894
662
|
if (keywordToken.kind === TokenKind.NAME) {
|
|
@@ -916,13 +684,6 @@ export class Parser {
|
|
|
916
684
|
}
|
|
917
685
|
throw this.unexpected(keywordToken);
|
|
918
686
|
}
|
|
919
|
-
/**
|
|
920
|
-
* ```
|
|
921
|
-
* SchemaExtension :
|
|
922
|
-
* - extend schema Directives[Const]? { OperationTypeDefinition+ }
|
|
923
|
-
* - extend schema Directives[Const]
|
|
924
|
-
* ```
|
|
925
|
-
*/
|
|
926
687
|
parseSchemaExtension() {
|
|
927
688
|
const start = this._lexer.token;
|
|
928
689
|
this.expectKeyword('extend');
|
|
@@ -938,10 +699,6 @@ export class Parser {
|
|
|
938
699
|
operationTypes,
|
|
939
700
|
});
|
|
940
701
|
}
|
|
941
|
-
/**
|
|
942
|
-
* ScalarTypeExtension :
|
|
943
|
-
* - extend scalar Name Directives[Const]
|
|
944
|
-
*/
|
|
945
702
|
parseScalarTypeExtension() {
|
|
946
703
|
const start = this._lexer.token;
|
|
947
704
|
this.expectKeyword('extend');
|
|
@@ -957,12 +714,6 @@ export class Parser {
|
|
|
957
714
|
directives,
|
|
958
715
|
});
|
|
959
716
|
}
|
|
960
|
-
/**
|
|
961
|
-
* ObjectTypeExtension :
|
|
962
|
-
* - extend type Name ImplementsInterfaces? Directives[Const]? FieldsDefinition
|
|
963
|
-
* - extend type Name ImplementsInterfaces? Directives[Const]
|
|
964
|
-
* - extend type Name ImplementsInterfaces
|
|
965
|
-
*/
|
|
966
717
|
parseObjectTypeExtension() {
|
|
967
718
|
const start = this._lexer.token;
|
|
968
719
|
this.expectKeyword('extend');
|
|
@@ -984,12 +735,6 @@ export class Parser {
|
|
|
984
735
|
fields,
|
|
985
736
|
});
|
|
986
737
|
}
|
|
987
|
-
/**
|
|
988
|
-
* InterfaceTypeExtension :
|
|
989
|
-
* - extend interface Name ImplementsInterfaces? Directives[Const]? FieldsDefinition
|
|
990
|
-
* - extend interface Name ImplementsInterfaces? Directives[Const]
|
|
991
|
-
* - extend interface Name ImplementsInterfaces
|
|
992
|
-
*/
|
|
993
738
|
parseInterfaceTypeExtension() {
|
|
994
739
|
const start = this._lexer.token;
|
|
995
740
|
this.expectKeyword('extend');
|
|
@@ -1011,11 +756,6 @@ export class Parser {
|
|
|
1011
756
|
fields,
|
|
1012
757
|
});
|
|
1013
758
|
}
|
|
1014
|
-
/**
|
|
1015
|
-
* UnionTypeExtension :
|
|
1016
|
-
* - extend union Name Directives[Const]? UnionMemberTypes
|
|
1017
|
-
* - extend union Name Directives[Const]
|
|
1018
|
-
*/
|
|
1019
759
|
parseUnionTypeExtension() {
|
|
1020
760
|
const start = this._lexer.token;
|
|
1021
761
|
this.expectKeyword('extend');
|
|
@@ -1033,11 +773,6 @@ export class Parser {
|
|
|
1033
773
|
types,
|
|
1034
774
|
});
|
|
1035
775
|
}
|
|
1036
|
-
/**
|
|
1037
|
-
* EnumTypeExtension :
|
|
1038
|
-
* - extend enum Name Directives[Const]? EnumValuesDefinition
|
|
1039
|
-
* - extend enum Name Directives[Const]
|
|
1040
|
-
*/
|
|
1041
776
|
parseEnumTypeExtension() {
|
|
1042
777
|
const start = this._lexer.token;
|
|
1043
778
|
this.expectKeyword('extend');
|
|
@@ -1055,11 +790,6 @@ export class Parser {
|
|
|
1055
790
|
values,
|
|
1056
791
|
});
|
|
1057
792
|
}
|
|
1058
|
-
/**
|
|
1059
|
-
* InputObjectTypeExtension :
|
|
1060
|
-
* - extend input Name Directives[Const]? InputFieldsDefinition
|
|
1061
|
-
* - extend input Name Directives[Const]
|
|
1062
|
-
*/
|
|
1063
793
|
parseInputObjectTypeExtension() {
|
|
1064
794
|
const start = this._lexer.token;
|
|
1065
795
|
this.expectKeyword('extend');
|
|
@@ -1093,12 +823,6 @@ export class Parser {
|
|
|
1093
823
|
directives,
|
|
1094
824
|
});
|
|
1095
825
|
}
|
|
1096
|
-
/**
|
|
1097
|
-
* ```
|
|
1098
|
-
* DirectiveDefinition :
|
|
1099
|
-
* - Description? directive @ Name ArgumentsDefinition? `repeatable`? on DirectiveLocations
|
|
1100
|
-
* ```
|
|
1101
|
-
*/
|
|
1102
826
|
parseDirectiveDefinition() {
|
|
1103
827
|
const start = this._lexer.token;
|
|
1104
828
|
const description = this.parseDescription();
|
|
@@ -1123,44 +847,9 @@ export class Parser {
|
|
|
1123
847
|
locations,
|
|
1124
848
|
});
|
|
1125
849
|
}
|
|
1126
|
-
/**
|
|
1127
|
-
* DirectiveLocations :
|
|
1128
|
-
* - `|`? DirectiveLocation
|
|
1129
|
-
* - DirectiveLocations | DirectiveLocation
|
|
1130
|
-
*/
|
|
1131
850
|
parseDirectiveLocations() {
|
|
1132
851
|
return this.delimitedMany(TokenKind.PIPE, this.parseDirectiveLocation);
|
|
1133
852
|
}
|
|
1134
|
-
/*
|
|
1135
|
-
* DirectiveLocation :
|
|
1136
|
-
* - ExecutableDirectiveLocation
|
|
1137
|
-
* - TypeSystemDirectiveLocation
|
|
1138
|
-
*
|
|
1139
|
-
* ExecutableDirectiveLocation : one of
|
|
1140
|
-
* `QUERY`
|
|
1141
|
-
* `MUTATION`
|
|
1142
|
-
* `SUBSCRIPTION`
|
|
1143
|
-
* `FIELD`
|
|
1144
|
-
* `FRAGMENT_DEFINITION`
|
|
1145
|
-
* `FRAGMENT_SPREAD`
|
|
1146
|
-
* `INLINE_FRAGMENT`
|
|
1147
|
-
* `VARIABLE_DEFINITION`
|
|
1148
|
-
* `FRAGMENT_VARIABLE_DEFINITION`
|
|
1149
|
-
*
|
|
1150
|
-
* TypeSystemDirectiveLocation : one of
|
|
1151
|
-
* `SCHEMA`
|
|
1152
|
-
* `SCALAR`
|
|
1153
|
-
* `OBJECT`
|
|
1154
|
-
* `FIELD_DEFINITION`
|
|
1155
|
-
* `ARGUMENT_DEFINITION`
|
|
1156
|
-
* `INTERFACE`
|
|
1157
|
-
* `UNION`
|
|
1158
|
-
* `ENUM`
|
|
1159
|
-
* `ENUM_VALUE`
|
|
1160
|
-
* `INPUT_OBJECT`
|
|
1161
|
-
* `INPUT_FIELD_DEFINITION`
|
|
1162
|
-
* `DIRECTIVE_DEFINITION`
|
|
1163
|
-
*/
|
|
1164
853
|
parseDirectiveLocation() {
|
|
1165
854
|
const start = this._lexer.token;
|
|
1166
855
|
const name = this.parseName();
|
|
@@ -1169,15 +858,6 @@ export class Parser {
|
|
|
1169
858
|
}
|
|
1170
859
|
throw this.unexpected(start);
|
|
1171
860
|
}
|
|
1172
|
-
// Implements the parsing rules in the Schema Coordinates section.
|
|
1173
|
-
/**
|
|
1174
|
-
* SchemaCoordinate :
|
|
1175
|
-
* - Name
|
|
1176
|
-
* - Name . Name
|
|
1177
|
-
* - Name . Name ( Name : )
|
|
1178
|
-
* - @ Name
|
|
1179
|
-
* - @ Name ( Name : )
|
|
1180
|
-
*/
|
|
1181
861
|
parseSchemaCoordinate() {
|
|
1182
862
|
const start = this._lexer.token;
|
|
1183
863
|
const ofDirective = this.expectOptionalToken(TokenKind.AT);
|
|
@@ -1226,28 +906,15 @@ export class Parser {
|
|
|
1226
906
|
name,
|
|
1227
907
|
});
|
|
1228
908
|
}
|
|
1229
|
-
// Core parsing utility functions
|
|
1230
|
-
/**
|
|
1231
|
-
* Returns a node that, if configured to do so, sets a "loc" field as a
|
|
1232
|
-
* location object, used to identify the place in the source that created a
|
|
1233
|
-
* given parsed object.
|
|
1234
|
-
*/
|
|
1235
909
|
node(startToken, node) {
|
|
1236
910
|
if (this._options.noLocation !== true) {
|
|
1237
911
|
node.loc = new Location(startToken, this._lexer.lastToken, this._lexer.source);
|
|
1238
912
|
}
|
|
1239
913
|
return node;
|
|
1240
914
|
}
|
|
1241
|
-
/**
|
|
1242
|
-
* Determines if the next token is of a given kind
|
|
1243
|
-
*/
|
|
1244
915
|
peek(kind) {
|
|
1245
916
|
return this._lexer.token.kind === kind;
|
|
1246
917
|
}
|
|
1247
|
-
/**
|
|
1248
|
-
* If the next token is of the given kind, return that token after advancing the lexer.
|
|
1249
|
-
* Otherwise, do not change the parser state and throw an error.
|
|
1250
|
-
*/
|
|
1251
918
|
expectToken(kind) {
|
|
1252
919
|
const token = this._lexer.token;
|
|
1253
920
|
if (token.kind === kind) {
|
|
@@ -1256,10 +923,6 @@ export class Parser {
|
|
|
1256
923
|
}
|
|
1257
924
|
throw syntaxError(this._lexer.source, token.start, `Expected ${getTokenKindDesc(kind)}, found ${getTokenDesc(token)}.`);
|
|
1258
925
|
}
|
|
1259
|
-
/**
|
|
1260
|
-
* If the next token is of the given kind, return "true" after advancing the lexer.
|
|
1261
|
-
* Otherwise, do not change the parser state and return "false".
|
|
1262
|
-
*/
|
|
1263
926
|
expectOptionalToken(kind) {
|
|
1264
927
|
const token = this._lexer.token;
|
|
1265
928
|
if (token.kind === kind) {
|
|
@@ -1268,10 +931,6 @@ export class Parser {
|
|
|
1268
931
|
}
|
|
1269
932
|
return false;
|
|
1270
933
|
}
|
|
1271
|
-
/**
|
|
1272
|
-
* If the next token is a given keyword, advance the lexer.
|
|
1273
|
-
* Otherwise, do not change the parser state and throw an error.
|
|
1274
|
-
*/
|
|
1275
934
|
expectKeyword(value) {
|
|
1276
935
|
const token = this._lexer.token;
|
|
1277
936
|
if (token.kind === TokenKind.NAME && token.value === value) {
|
|
@@ -1281,10 +940,6 @@ export class Parser {
|
|
|
1281
940
|
throw syntaxError(this._lexer.source, token.start, `Expected "${value}", found ${getTokenDesc(token)}.`);
|
|
1282
941
|
}
|
|
1283
942
|
}
|
|
1284
|
-
/**
|
|
1285
|
-
* If the next token is a given keyword, return "true" after advancing the lexer.
|
|
1286
|
-
* Otherwise, do not change the parser state and return "false".
|
|
1287
|
-
*/
|
|
1288
943
|
expectOptionalKeyword(value) {
|
|
1289
944
|
const token = this._lexer.token;
|
|
1290
945
|
if (token.kind === TokenKind.NAME && token.value === value) {
|
|
@@ -1293,18 +948,10 @@ export class Parser {
|
|
|
1293
948
|
}
|
|
1294
949
|
return false;
|
|
1295
950
|
}
|
|
1296
|
-
/**
|
|
1297
|
-
* Helper function for creating an error when an unexpected lexed token is encountered.
|
|
1298
|
-
*/
|
|
1299
951
|
unexpected(atToken) {
|
|
1300
952
|
const token = atToken ?? this._lexer.token;
|
|
1301
953
|
return syntaxError(this._lexer.source, token.start, `Unexpected ${getTokenDesc(token)}.`);
|
|
1302
954
|
}
|
|
1303
|
-
/**
|
|
1304
|
-
* Returns a possibly empty list of parse nodes, determined by the parseFn.
|
|
1305
|
-
* This list begins with a lex token of openKind and ends with a lex token of closeKind.
|
|
1306
|
-
* Advances the parser to the next lex token after the closing token.
|
|
1307
|
-
*/
|
|
1308
955
|
any(openKind, parseFn, closeKind) {
|
|
1309
956
|
this.expectToken(openKind);
|
|
1310
957
|
const nodes = [];
|
|
@@ -1313,12 +960,6 @@ export class Parser {
|
|
|
1313
960
|
}
|
|
1314
961
|
return nodes;
|
|
1315
962
|
}
|
|
1316
|
-
/**
|
|
1317
|
-
* Returns a list of parse nodes, determined by the parseFn.
|
|
1318
|
-
* It can be empty only if open token is missing otherwise it will always return non-empty list
|
|
1319
|
-
* that begins with a lex token of openKind and ends with a lex token of closeKind.
|
|
1320
|
-
* Advances the parser to the next lex token after the closing token.
|
|
1321
|
-
*/
|
|
1322
963
|
optionalMany(openKind, parseFn, closeKind) {
|
|
1323
964
|
if (this.expectOptionalToken(openKind)) {
|
|
1324
965
|
const nodes = [];
|
|
@@ -1329,11 +970,6 @@ export class Parser {
|
|
|
1329
970
|
}
|
|
1330
971
|
return undefined;
|
|
1331
972
|
}
|
|
1332
|
-
/**
|
|
1333
|
-
* Returns a non-empty list of parse nodes, determined by the parseFn.
|
|
1334
|
-
* This list begins with a lex token of openKind and ends with a lex token of closeKind.
|
|
1335
|
-
* Advances the parser to the next lex token after the closing token.
|
|
1336
|
-
*/
|
|
1337
973
|
many(openKind, parseFn, closeKind) {
|
|
1338
974
|
this.expectToken(openKind);
|
|
1339
975
|
const nodes = [];
|
|
@@ -1342,11 +978,6 @@ export class Parser {
|
|
|
1342
978
|
} while (!this.expectOptionalToken(closeKind));
|
|
1343
979
|
return nodes;
|
|
1344
980
|
}
|
|
1345
|
-
/**
|
|
1346
|
-
* Returns a non-empty list of parse nodes, determined by the parseFn.
|
|
1347
|
-
* This list may begin with a lex token of delimiterKind followed by items separated by lex tokens of tokenKind.
|
|
1348
|
-
* Advances the parser to the next lex token after last item in the list.
|
|
1349
|
-
*/
|
|
1350
981
|
delimitedMany(delimiterKind, parseFn) {
|
|
1351
982
|
this.expectOptionalToken(delimiterKind);
|
|
1352
983
|
const nodes = [];
|
|
@@ -1366,16 +997,10 @@ export class Parser {
|
|
|
1366
997
|
}
|
|
1367
998
|
}
|
|
1368
999
|
}
|
|
1369
|
-
/**
|
|
1370
|
-
* A helper function to describe a token as a string for debugging.
|
|
1371
|
-
*/
|
|
1372
1000
|
function getTokenDesc(token) {
|
|
1373
1001
|
const value = token.value;
|
|
1374
1002
|
return getTokenKindDesc(token.kind) + (value != null ? ` "${value}"` : '');
|
|
1375
1003
|
}
|
|
1376
|
-
/**
|
|
1377
|
-
* A helper function to describe a token kind as a string for debugging.
|
|
1378
|
-
*/
|
|
1379
1004
|
function getTokenKindDesc(kind) {
|
|
1380
1005
|
return isPunctuatorTokenKind(kind) ? `"${kind}"` : kind;
|
|
1381
1006
|
}
|