[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#71760: 31.0.50; Filling jsdoc text doesn't work in js-ts-mode
From: |
Damien Cassou |
Subject: |
bug#71760: 31.0.50; Filling jsdoc text doesn't work in js-ts-mode |
Date: |
Mon, 24 Jun 2024 22:23:06 +0200 |
Hi,
in a commit recently merged in master (0edacf2aa7e53), js-ts-mode has
been improved to use the jsdoc treesitter grammar on documentation. Font
lock works great but M-q doesn't fill long lines.
To reproduce, make sure your Emacs contains the above-mentioned commit
and make sure you have the jsdoc treesitter grammar available. Then,
save the attached JavaScript file to your disk and execute:
$ emacs -Q --eval "(progn (find-file \"/home/cassou/tmp/test.js\")
(js-ts-mode))"
Move point to the middle of line 2 (or line 4) and press M-q.
Expected: The paragraph is filled.
Actual: Nothing changes.
I tried changing the value of `c-ts-common--comment-regexp' to include
"description" (as this is what the jsdoc parser uses for text) but the
result is worse. I also tried reusing `js-fill-paragraph' but that fails
as well.
I would be happy to implement something and send a patch but I have no
idea were to start.
--
Damien Cassou
"Success is the ability to go from one failure to another without
losing enthusiasm." --Winston Churchill
test.js
Description: Text Data
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- bug#71760: 31.0.50; Filling jsdoc text doesn't work in js-ts-mode,
Damien Cassou <=