Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Weird footnote display #33

Closed
dangom opened this issue Nov 21, 2018 · 5 comments
Closed

Weird footnote display #33

dangom opened this issue Nov 21, 2018 · 5 comments

Comments

@dangom
Copy link

dangom commented Nov 21, 2018

Describe the bug

Sometimes the following, in a markdown file:

<sup>
    <a id="fnr.1" class="footref" href="#fn.1">1</a>
</sup>

Will be transformed into the following html:

<sup>
    <a id="fnr.1" class="footref">
        <span>#</span><span class="p-category">fn</span>
    </a>.1”&gt;1
</sup>

Some weird interaction of the href hashtag?

Steps to reproduce (if necessary)

Steps to reproduce the behavior:
Not sure. In a minimal markdown file things worked ok, so I couldn't reproduce. But checkout broken footnote links here.

Expected behavior

Instead of being displayed like:
#fn.1”>1

The footnote link would be:
1

@thebaer
Copy link
Member

thebaer commented Nov 21, 2018

Yeah, in addition to problems in code blocks (#6), the hashtag parsing messes up hash links. The current workaround is to do:

[1](my-slug#fn.1)

Or in HTML:

<sup>
    <a id="fnr.1" class="footref" href="my-slug#fn.1">1</a>
</sup>

Will get this fixed.

mrvdb referenced this issue in mrvdb/writefreely Dec 3, 2018
This improves rendering in a number of situations:

- it keeps anchor tags working
- it gives the user some control for not linking, for example in code
  blocks.

Con:
hashTags at the beginning of a line without a space won't get linked.

Workaround related to issues #42 and #6 and #33
@thebaer thebaer added this to the 1.0 milestone Jan 25, 2019
@thebaer thebaer closed this as completed Feb 1, 2019
@thebaer
Copy link
Member

thebaer commented Feb 1, 2019

Fixed in #43

@dangom
Copy link
Author

dangom commented Feb 1, 2019

This is awesome. When should we expect the changes to land on write.as?!

@thebaer
Copy link
Member

thebaer commented Feb 2, 2019

It's live now! :)

@eternaltyro
Copy link

[1](my-slug#fn.1)

Is this behavior documented? I'm trying to figure out how to add footnotes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants