]> git.eshelyaron.com Git - emacs.git/commitdiff
Tweak s-p-f for js-ts-mode
authorDmitry Gutov <dmitry@gutov.dev>
Tue, 12 Sep 2023 23:21:04 +0000 (02:21 +0300)
committerDmitry Gutov <dmitry@gutov.dev>
Tue, 12 Sep 2023 23:21:04 +0000 (02:21 +0300)
* lisp/progmodes/js.el (js-ts--s-p-query):
Consider two more contexts (bug#65470).

lisp/progmodes/js.el

index 9b6da4ec2fcdbfff3e6bc4a0f7c35fb6792fe8fd..1528c6b7de5b8dabbd3ce8e314fe726a2de5f573 100644 (file)
@@ -3871,6 +3871,8 @@ Currently there are `js-mode' and `js-ts-mode'."
                            '(((regex pattern: (regex_pattern) @regexp))
                              ((variable_declarator value: (jsx_element) @jsx))
                              ((assignment_expression right: (jsx_element) @jsx))
+                             ((arguments (jsx_element) @jsx))
+                             ((parenthesized_expression (jsx_element) @jsx))
                              ((return_statement (jsx_element) @jsx))))))
 
 (defun js-ts--syntax-propertize (beg end)