finds.dev← search

// the find

spilikin/tree-sitter-fsh

C · MIT · updated May 2026

Tree-sitter grammar for FHIR Shorthand (FSH 3.0.0)

A Tree-sitter grammar for FHIR Shorthand (FSH 3.0.0), the DSL used to author FHIR profiles and implementation guides. Useful to anyone building editor tooling — syntax highlighting, code navigation, linting — for FSH files in Neovim, Helix, Zed, or any Tree-sitter-aware editor. The target audience is small: HL7/FHIR tooling developers.

The maximal-munch approach to keyword/identifier disambiguation is the right call — ANTLR grammars often get this wrong and produce nonsense tokens in identifiers that happen to start with a keyword. Committing src/parser.c means downstream consumers (Zed extensions, etc.) don't need the full Node.js toolchain to compile the grammar. Porting directly from the official SUSHI ANTLR grammar is a defensible fidelity strategy rather than reverse-engineering from examples.

Zero stars, zero forks, no test suite beyond a single sample.fsh example — there's no corpus of FSH files validating edge cases, so grammar correctness beyond the happy path is unknown. No highlights.scm, locals.scm, or injections.scm query files means this produces a parse tree but gives editors nothing to actually highlight. No Neovim/Helix integration instructions despite those being the most likely consumers. FSH 3.0.0 is a specific version peg with no documented plan for keeping up with spec changes.

View on GitHub →

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →