From: Steinar Bang <sb@dod.no>
To: help-gnu-emacs@gnu.org
Subject: Re: JavaScript/TypeScript: What do people in 2024, on emacs 29, use for .js, .jsx, .ts and .tsx?
Date: Sat, 13 Jan 2024 08:30:53 +0100 [thread overview]
Message-ID: <877ckd7kr6.fsf@dod.no> (raw)
In-Reply-To: <87v8816txt.fsf@dod.no> (Steinar Bang's message of "Wed, 10 Jan 2024 17:21:02 +0100")
>>>>> Steinar Bang <sb@dod.no>:
>>>>> Dmitry Gutov <dmitry@gutov.dev>:
>> but some features (like tag splitting?) might have to be reimplemented
>> anew. Should be easier to do that using tree-sitter parse tree than
>> with sgml-mode. Perhaps if rjsx-mode has an implementation, it
>> wouldn't be too hard to port it.
> I'll do a dive into the rjsx code and see if I can identify where it
> does tag splitting and post back on the thread here.
Harder than I thought... parsing and manipulation of the buffer seems
interweaved, but perhaps here:
https://github.com/felipeochoa/rjsx-mode/blob/master/rjsx-mode.el#L452
If you have something like
<Home/>
and you type a ">" after "Home", i.e.
<Home></>
then the "</>" is immediately expanded to "</Home>"
<Home></Home>
And it, sort of, kind of, looks like the above code is the one doing it, maybe...?
(Couldn't figure out where js2-DIV and friends were defined so I don't
know what it matches)
next prev parent reply other threads:[~2024-01-13 7:30 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-09 12:12 JavaScript/TypeScript: What do people in 2024, on emacs 29, use for .js, .jsx, .ts and .tsx? Steinar Bang
2024-01-09 17:32 ` Dmitry Gutov
2024-01-10 16:21 ` Steinar Bang
2024-01-13 7:30 ` Steinar Bang [this message]
2024-01-14 21:00 ` Dmitry Gutov
2024-01-22 13:54 ` Steinar Bang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=877ckd7kr6.fsf@dod.no \
--to=sb@dod.no \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.