emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [FR] [Revived] Human readable / customizable link anchors during exp


From: Kévin Le Gouguec
Subject: Re: [FR] [Revived] Human readable / customizable link anchors during export
Date: Tue, 11 Oct 2022 21:20:01 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

Ihor Radchenko <yantar92@gmail.com> writes:

> 3. Instead of trying to find a silver bullet for human-readable anchor
>    generator, we allow users to customize it. The default will be
>    constant "org" yielding "org-Ajjq"-type anchors, just like we have
>    now. But we can also provide other generators, like the one Timothy
>    proposed, or better versions contributed in future if there is
>    demand.

Personally, I'd be wholly satisfied with a customization option; the
grail for me would be [pandoc's algorithm], which doesn't look too hard
to reimplement in one's config.

(Although the collision-handling logic could be tricky: since it
revolves around appending a counter to the ID, it needs to keep track of
how many times the same ID has been generated for the whole document.
If the generator API is just {heading ↦ ID}, i.e. there is no extra
"context" argument, one will need to do some bookkeeping "on the
side"…)

[pandoc's algorithm]: https://pandoc.org/MANUAL.html#extension-auto_identifiers



reply via email to

[Prev in Thread] Current Thread [Next in Thread]