
9/11/2023
What this post added
This post details the technical implementation of integrating the ShopifyQL language server with the CodeMirror editor. Key contributions include: developing a custom adapter to bridge the Language Server Protocol (LSP) and CodeMirror's Lezer parser, solving complex token offset calculations from ANTLR's incremental, relative positioning to CodeMirror's document-relative offsets, and implementing a `TokenIterator` class to manage this conversion. It also describes how the language server's features (completion, linting, hover tooltips) were connected to CodeMirror plugins via the custom adapter.