UNPKG

2.58 kBJavaScriptView Raw
1"use strict";
2
3Object.defineProperty(exports, "__esModule", {
4 value: true
5});
6exports.getIntrospectionQuery = getIntrospectionQuery;
7exports.introspectionQuery = void 0;
8
9/**
10 * Copyright (c) 2015-present, Facebook, Inc.
11 *
12 * This source code is licensed under the MIT license found in the
13 * LICENSE file in the root directory of this source tree.
14 *
15 *
16 */
17function getIntrospectionQuery(options) {
18 var descriptions = !(options && options.descriptions === false);
19 return "\n query IntrospectionQuery {\n __schema {\n queryType { name }\n mutationType { name }\n subscriptionType { name }\n types {\n ...FullType\n }\n directives {\n name\n ".concat(descriptions ? 'description' : '', "\n locations\n args {\n ...InputValue\n }\n }\n }\n }\n\n fragment FullType on __Type {\n kind\n name\n ").concat(descriptions ? 'description' : '', "\n fields(includeDeprecated: true) {\n name\n ").concat(descriptions ? 'description' : '', "\n args {\n ...InputValue\n }\n type {\n ...TypeRef\n }\n isDeprecated\n deprecationReason\n }\n inputFields {\n ...InputValue\n }\n interfaces {\n ...TypeRef\n }\n enumValues(includeDeprecated: true) {\n name\n ").concat(descriptions ? 'description' : '', "\n isDeprecated\n deprecationReason\n }\n possibleTypes {\n ...TypeRef\n }\n }\n\n fragment InputValue on __InputValue {\n name\n ").concat(descriptions ? 'description' : '', "\n type { ...TypeRef }\n defaultValue\n }\n\n fragment TypeRef on __Type {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n }\n }\n }\n }\n }\n }\n }\n }\n ");
20}
21/**
22 * Deprecated, call getIntrospectionQuery directly.
23 *
24 * This function will be removed in v15
25 */
26
27
28var introspectionQuery = getIntrospectionQuery();
29exports.introspectionQuery = introspectionQuery;
\No newline at end of file