Re: Multiple anchors/ids for description list item (glossary pluralization)
Posted by
habamax on
May 22, 2020; 2:41pm
URL: https://discuss.asciidoctor.org/Multiple-anchors-ids-for-description-list-item-glossary-pluralization-tp8036p8037.html
On 22.05.2020 17:33, oddhack [via Asciidoctor :: Discussion] wrote:
> I'm trying to reproduce the functionality of LaTeX glossary package
> \glspl{term}, which produces a link to the glossary for the specified
> term, but puts it in text as pluralized (e.g. "terms" would link to
> the glossary "term" entry). My first thought was
>
> [[terms]]term:: A term
>
> But while <<term>> and <<terms>> do both link to this, the former
> shows up with the rendered "[term]" style in HTML output. I can say
> <<term,term>> and avoid this ugliness, but that makes markup
> considerably longer to write. There doesn't seem to be a way to
> specify multiple anchors on a list item, so I can't say something like
>
I don't think <<term>> would link to [[terms]]. And actually that is why
it is rendered as [term] in your html.
>
> Are there better / different options that allow interchangeable use of
> the singular and plural terms to link to the same glossary term?
> Writing a Ruby macro is off the table learning curve-wise.
>
Why wouldn't you use [[term, terms]] and use <<term>> to show urls as
terms? And if you need to name it differently, use <<term, Longer
description of the url>> ?