mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-14 17:30:08 -04:00
Add tree-sitter grammar for TOON (Token-Oriented Object Notation), a JSON-alternative data format with indentation-based structure. - Add parser config in parsers.lua - Add query files: highlights, folds, indents, locals Parser repository: https://github.com/DanEscher98/tree-sitter-toon TOON spec: https://github.com/toon-format/spec 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
15 lines
426 B
Scheme
15 lines
426 B
Scheme
; locals.scm - Local scope and reference queries for TOON
|
|
; Used for features like go-to-definition, scope highlighting
|
|
; Each object creates a new scope
|
|
(object) @local.scope
|
|
|
|
; Keys define local names within their scope
|
|
(pair
|
|
key: (key) @local.definition)
|
|
|
|
; Array declarations define names
|
|
(array_declaration
|
|
key: (key) @local.definition)
|
|
|
|
; Field names in tabular arrays are definitions
|
|
(field_name) @local.definition
|