Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
42dde46e
Commit
42dde46e
authored
Feb 13, 2020
by
Simon Knox
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix code example for GraphQL usage outside of Vue
parent
b9940c46
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
doc/development/fe_guide/graphql.md
doc/development/fe_guide/graphql.md
+4
-2
No files found.
doc/development/fe_guide/graphql.md
View file @
42dde46e
...
...
@@ -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
d
efaultClient
from
'
~/lib/graphql
'
;
import
createD
efaultClient
from
'
~/lib/graphql
'
;
import
query
from
'
./query.graphql
'
;
defaultClient
.
query
(
query
)
const
defaultClient
=
createDefaultClient
();
defaultClient
.
query
({
query
})
.
then
(
result
=>
console
.
log
(
result
));
```
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment