graphql-for-vscode icon indicating copy to clipboard operation
graphql-for-vscode copied to clipboard

How to deal with remote schemas?

Open rankun203 opened this issue 7 years ago • 1 comments

When writing GraphQL Schemas, we use a .gql file to enable highlighting and auto completing. But if there are other services exposes a graphql schema, we currently do not have a way to reference it in our *.gql files, how can we do that? For letting current project remote schemas don't report errors.

rankun203 avatar Jun 17 '18 16:06 rankun203

Not sure if this is of any help, but take a look at graphql-cli. It lets you fetch remote schema and save it to a file with this command:

graphql get-schema -e <url> --all false -o <outFile>

I don't work with the .gql files ever, but I suppose you can then reference this exported file?

VojtechStep avatar Jun 29 '18 15:06 VojtechStep