From 22178a6c2efe82921328f6bd97f644deb9828450 Mon Sep 17 00:00:00 2001 From: Andrew Bastin Date: Tue, 5 May 2020 17:28:43 -0400 Subject: [PATCH] Docs are persisted and regenerated from the schema introspection data --- pages/graphql.vue | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pages/graphql.vue b/pages/graphql.vue index 252bb9900..233689c4a 100644 --- a/pages/graphql.vue +++ b/pages/graphql.vue @@ -432,6 +432,13 @@ export default { return result === "" ? "" : `${result}` }, }, + mounted() { + if (this.$store.state.gql.schemaIntrospection && this.$store.state.gql.schema) { + const gqlSchema = gql.buildClientSchema(JSON.parse(this.$store.state.gql.schemaIntrospection)) + + this.getDocsFromSchema(gqlSchema) + } + }, methods: { getSpecialKey: getPlatformSpecialKey, doPrettifyQuery() {