- you want to have a very large document, but avoid header names collision
- painfully, github's markdown/rst/asciidoc do not allow to give a header a custom anchor id/link
- so, if you have
## some header
or
== some header
or
***
some header
- you are stuck with github.com/link-to-doc#some-header
- you cannot use raw
<h2 id="different-anchor">some-header</h2>
either, it still gets replaced with #some-header
## First heading <sup><sup><sub>2020-09-05 <a name="235ffda" href="#235ffda">235ffda</a></sub></sup></sup>
- renders as
First heading 2020-09-05 235ffda
- use headers freely, but append to each
<sup><sup><sub>2020-09-05 <a name="235ffda" href="#235ffda">235ffda</a></sub></sup></sup>
- where a random hash gives any header uniqueness
- yes, it is a little taxing code-wise, but:
- you get standard readable links to your header still, but with hash appended
- if you rename the header and link breaks, user can use hash from old link to find the same header, but with new title
- because hash of every header in the documnet never-ever changes, HOORAY!
- or: hash itself is a link(anchor) and user can copy that link, which will never break
- at the cost of having a small superscript over every header, you get header-name-freedom and unique persistent links
- best of both worlds - auto generated header link and unique persisten hash for every single header
- ad
- ff
First heading 2020-09-05 4dsdwd1c
- some blue text.
- a
- b
First heading 2020-09-05 53cf31
- some blue text.
- a
- b
- some blue text.
- a
- b
- some blue text.
- a
- b
First heading link
- a
- b
- a
- b
- a
- b
- a
- b
- a
- b
- a
- b
- a
- b
- 1
- 2
#
Second heading
- a
- a
First heading #
- a
- b
- a
- c
- 1
- 2
- 1
- 2
- wer
- rtgrq
- 1
- 2
blah blah
- asd
- few
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar
- foo
- bar