Re: [ELPA] New package: markdown-ts-appear

Stéphane Marks <[email protected]>
Newsgroups gmane.emacs.devel
Message-ID <CAN+1HbohZV0qkoHpq17uN07-A2xoV3mOgMxVBq2oPcN7P3d-jQ@mail.gmail.com>
On Thu, Sep 3, 2026 at 11:52 AM Philip Kaludercic <[email protected]>
wrote:

> 强生 <[email protected]> writes:
>
> > Hello,
> >
> > I would like to submit markdown-ts-appear to NonGNU ELPA.
> >
> > markdown-ts-appear is a minor mode for Emacs 31's built-in
> > markdown-ts-mode. It hides Markdown markup while reading and reveals
> > the smallest semantic element at point while editing. It also provides
> > optional asynchronous MathJax previews and visual decorations for code
> > blocks, callouts, block quotes, links, and tables.
> >
> > Repository:
> > https://github.com/Thysrael/markdown-ts-appear
>
> As the code is AI generated, I'll just leave a few high level comments:
>
> - You don't need the :group annotations in user options, they fall back
>   to the last defgroup.
>
> - Can you set the default value of
>   `markdown-ts-appear-enable-math-preview' to be (package-installed-p
>   'Mathias)?
>
> - The logic do draw a box around a code block uses these BOX DRAWINGS
>   characters that don't always look good with all fonts.  I would
>   recommend re-thinking this, or just plain avoiding using text to draw.
>
> Otherwise the code seems OK from a skim, albeit very verbose.  I cannot
> judge just from reading (and cannot test it since I don't build Emacs
> with tree sitter) but I have difficulties believing that the entire 2400
> lines of code are all there to match the necessary complexity of the
> problem you are trying to solve.  Please keep in mind that just because
> you use an LLM, doesn't mean that humans don't want to read and change
> the code as well without being exhausted, so it valuable to keep the
> codebase "human sized".
>
> Other than that I have CC'ed the markdown-ts-mode maintainers Stephane
> and Rahul for further comments.  Sadly the features of this package are
> currently not candidates for upstreaming, but perhaps they have a better
> feeling if the package suggestion makes sense in the current form.
> Specifically I would be interested if we could avoid the advice block at
> the end of the file.
>

Thanks.  I'll take a deeper look when I have time.  At first glance, the
name itself probably should be "markdown-ts-reveal" not "appear".  I'd
probably want to separate showing strict Markdown markup when markup is
hidden from the other features like math and evil/meow integration.  I
agree it appears (pun intended) that there is a lot of code for what it
does and not all of it is idiomatic ELisp, but that is separate from
whether it works or not.

+ Andrea Alberti who has a lot more LaTeX experience than I do and he's
contributed to the core mode with depth of knowledge.  I seem to recall
that he may have a similar "reveal" functionality somewhere and has, I
think, contributed a to-do list item to improve markup editing while markup
is hidden.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.