From b403c199dfd4491e1c1bcec2b4fed257f5e0e51a Mon Sep 17 00:00:00 2001 From: KyleBarton Date: Wed, 12 Nov 2025 11:59:10 -0800 Subject: [PATCH] Add additional comment for context in Tyepscript highlights (#42564) This adds additional comments which were left out from #42494 by accident. Namely, it describes why we have additional custom highlighting in `highlights.scm` for the Typescript grammar. Release Notes: - N/A --- crates/languages/src/typescript/highlights.scm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/crates/languages/src/typescript/highlights.scm b/crates/languages/src/typescript/highlights.scm index 14f6e2203476e5483af5bc21b69b6c62019c6b82..5e8d55581e3ae86c85ca2b845e8a07caa6444c1d 100644 --- a/crates/languages/src/typescript/highlights.scm +++ b/crates/languages/src/typescript/highlights.scm @@ -9,6 +9,9 @@ (type_identifier) @type (predefined_type) @type.builtin +;; Enables ts-pretty-errors +;; The Lsp returns "snippets" of typescript, which are not valid typescript in totality, +;; but should still be highlighted ;; Highlights object literals by hijacking the statement_block pattern, but only if ;; the statement block follows an object literal pattern ((statement_block