codemirror-graphql

JSON →
library 2.2.7 ·javascript
verified Jun 7, 2026

Provides CodeMirror 5 with a dedicated parser mode for GraphQL, along with live linting and typeahead autocompletion powered by a GraphQL schema. Version 2.2.7 is the latest stable release in the 2.x line, which targets CodeMirror 5 (not CodeMirror 6—use cm6-graphql for CM6). The package supports GraphQL v15, v16, and v17. It is part of the GraphiQL ecosystem and is maintained by the GraphQL Foundation. Key differentiators include deep integration with GraphQL schemas for context-aware hints and validation, support for external fragments, and custom validation rules.