diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-13 12:08:49 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-13 12:08:49 +0000 |
commit | 1308dc5eb484ab0f8064989fc551ebdb4b1a7976 (patch) | |
tree | 614a93d9bf8df34ecfc25c02648329987fb21dde /doc/development/fe_guide | |
parent | f0707f413ce49b5712fca236b950acbec029be1e (diff) | |
download | gitlab-ce-1308dc5eb484ab0f8064989fc551ebdb4b1a7976.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/development/fe_guide')
-rw-r--r-- | doc/development/fe_guide/graphql.md | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/doc/development/fe_guide/graphql.md b/doc/development/fe_guide/graphql.md index 68c0c1e3370..a9821edff0b 100644 --- a/doc/development/fe_guide/graphql.md +++ b/doc/development/fe_guide/graphql.md @@ -425,10 +425,12 @@ It is also possible to use GraphQL outside of Vue by directly importing and using the default client with queries. ```javascript -import defaultClient from '~/lib/graphql'; +import createDefaultClient from '~/lib/graphql'; import query from './query.graphql'; -defaultClient.query(query) +const defaultClient = createDefaultClient(); + +defaultClient.query({ query }) .then(result => console.log(result)); ``` |