MCPcopy Create free account
hub / github.com/subquery/subql / buildSchemaFromString

Function buildSchemaFromString

packages/utils/src/graphql/schema.ts:18–22  ·  view source on GitHub ↗
(raw: string)

Source from the content-addressed store, hash-verified

16}
17
18export function buildSchemaFromString(raw: string): GraphQLSchema {
19 const src = new Source(raw);
20 const doc = parse(src);
21 return buildSchemaFromDocumentNode(doc);
22}
23
24export function buildSchemaFromDocumentNode(doc: DocumentNode): GraphQLSchema {
25 return extendSchema(loadBaseSchema(), doc);

Callers 7

createMethod · 0.90
loadGqlSchemaFunction · 0.90
buildSchemaFromFileFunction · 0.85

Calls 1

Tested by 1

loadGqlSchemaFunction · 0.72