Nicolas Goaziou <m...@nicolasgoaziou.fr> writes:
> I don't think such a system would preserve properties offered by > `org-export-get-reference', for example in non-latin languages. Also, > header content is not stable enough: when you're linking to the custom > ID, you may be able to change the title and yet preserve the link. > > However, your proposal may be an improvement over > `org-export-get-reference' in the context of "ox-html.el", that I don't > know. That's the second way I wrote about. My proposal basically replaces the random hex generating function in `org-export-get-reference' with a call to a function `org-reference-contraction' which takes a header and outputs a string like "some-header-string" and then has digits appended should it be non-unique (i.e. "some-header-string-2", "some-header-string-3"). For certain recognised blocks (e.g. src and example blocks) it appends ",{block}--{n}", for example: "some-header-string,code--1". I consider this to be quite a nice improvement. -- Timothy