Skip to content

Editor integration

Vertex ships a Language Server (LSP) and a tree-sitter grammar. Any editor that can drive an LSP server and load a tree-sitter grammar can provide a first-class Vertex experience. The Zed extension is the reference integration.

For step-by-step install instructions, see Editor setup. This page documents what the LSP actually does.

CapabilityStatusNotes
Diagnostics (push)YesReal-time as you type. Every checker error and warning flows through.
CompletionsYesKeywords, built-in types, annotation names, stdlib members, identifiers in scope.
HoverPartialShows types for identifiers with a meaningful declaration site.
Go to definitionPartialFor top-level declarations with a resolvable source.
FormattingNoFormatter not yet available.
RenameNoNot yet supported.

Diagnostic spans are first-class: a red squiggle lands exactly at the offending token, and multi-location errors (for example, conflicting declarations) highlight every related span.

The extension at vertex-run/zed-vertex wires everything up automatically:

  • Downloads the vertex binary for your platform, or uses the one on your PATH.
  • Launches vertex lsp for each .vtx buffer.
  • Loads the tree-sitter-vertex grammar for highlighting.

Install it from Zed’s extensions pane.

Launch command:

vertex lsp

This reads and writes the LSP protocol on stdin/stdout. No arguments, no initialization options.

Client configuration varies by editor. In general you need:

  • Language ID: vertex
  • File pattern: *.vtx
  • Server command: vertex lsp (with vertex on PATH)
  • Workspace root: the nearest ancestor containing sfdx-project.json

The grammar at vertex-run/tree-sitter-vertex is the source of truth for syntax highlighting. Editors that load tree-sitter grammars directly (Neovim with nvim-treesitter, Helix, Zed) can use it without the LSP at all, though you lose diagnostics and completions.

Highlight queries cover keywords, types, string interpolation, operators, annotations, and comments.

Editor problems often come from one of three places:

  1. The LSP itself, for diagnostics, completions, or hover bugs. File against vertex-run/vertex.
  2. The grammar, for highlighting glitches or wrong tokenization. File against vertex-run/tree-sitter-vertex.
  3. The extension, for install or binary-download issues. File against vertex-run/zed-vertex.

A one-line reduced example and the LSP log (if your editor exposes it) is usually enough to identify which one it is.