From: Dmitry Gutov Date: Sat, 25 Feb 2023 01:54:31 +0000 (+0200) Subject: typescript-ts-mode: Highlight non-shorthand destructuring bindings X-Git-Tag: emacs-29.0.90~327 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c92360c7a3bf8f33d4fe4e7cc351c33ab4a7d5ca;p=emacs.git typescript-ts-mode: Highlight non-shorthand destructuring bindings * lisp/progmodes/typescript-ts-mode.el (typescript-ts-mode--font-lock-settings): Highlight non-shorthand variable bindings in object destructuring. --- diff --git a/lisp/progmodes/typescript-ts-mode.el b/lisp/progmodes/typescript-ts-mode.el index 64af5574f9f..5b49b8f50a8 100644 --- a/lisp/progmodes/typescript-ts-mode.el +++ b/lisp/progmodes/typescript-ts-mode.el @@ -272,7 +272,9 @@ Argument LANGUAGE is either `typescript' or `tsx'." :language language :feature 'pattern `((pair_pattern - key: (property_identifier) @font-lock-property-ref-face) + key: (property_identifier) @font-lock-property-ref-face + value: [(identifier) @font-lock-variable-name-face + (assignment_pattern left: (identifier) @font-lock-variable-name-face)]) (array_pattern (identifier) @font-lock-variable-name-face)