GraphQL for Visual Studio Code

GraphQL for Visual Studio Code
Average rating: 3.6
(8 votes)

Thanks! You’ve rated this material!

Last week we were happy to announce Visual Studio Code for Elixir. And now we’re introducing to you another cool thing – VSCode GraphQL extension! Features include intelligent autocompletion, jump-to-definition, syntax highlighting, query validation & a lot more.

Top 3 features of the new VS Code plugin

  1.  Intelligent autocompletion. With the new VS Code plugin, your editor is now able to suggest types, fields and query arguments for your GraphQL code. The suggestions are based on the information provided in your GraphQL schema.
  2. Jump-to-definition.  For example, when you see a field inside a GraphQL query and want to learn more about its type, you can now Ctrl+Click on that field and VS Code will open the type inside the original SDL schema definition.
  3. Validate queries against your GraphQL schema. With the query validation feature, your editor will notify you about typos as well as structural and syntactical errors in your GraphQL code.

The plugin actually provides a lot more functionality:

  • Syntax highlighting
  • Validating SDL and outlining syntactical errors
  • Hovering over types & fields shows their description
  • Predefined code snippets (e.g. for creating new SDL types)
  • Validation and autocompletion for Prisma directives

For the VS Code plugin, you can soon expect more features like better handling of custom directives, support for graphql-import as well as associating your gql tags with specific schemas (for multi-schema projects). If you want to find out more about the plugin features, you can use that source and other materials.

Rate this article, if you like it

Thanks! You’ve rated this material!

Got a project? Let's discuss it!

    Kyiv Sofiivska 1/2a, 01001, Kyiv, Ukraine
    Dnipro Hlinky 2, of. 1003, 49000, Dnipro, Ukraine
    Kharkiv Otakara Yarosha 22, 61000, Kharkiv, Ukraine
    Email [email protected]