Closed GavinRay97 closed 4 years ago
Yeah, that was serious overlook, but it's fixed on master :)
Currently there is set of getter methods on documentSchemaApi
https://github.com/vadistic/graphql-extra/blob/d2367aedf3a9822bb24c8c88cfacf082b7d89587/src/core/document/document-schema.ts#L23-L50
I think there should be something like SchemaDefinitionApi
for this for full schema root crud :)
Yeah, so the above was totally rewritten - but now there is support for every kind of ast node.
Through a lucky guess, I found that removing the schema root operations will allow you to parse a schema with
documentApi.addSDL()
:It also works if you trim roughly the first ~90 chars off with substr (but that's a terrible pattern):