内联展开脚注的第二次出现无法展开

Using the footnote plugin v0.1 with settings “enable markdown footnotes” and “display footnotes inline” enabled on discourse 2.6.0 beta6 (66ecefba52) :

  • when the same inline footnote is used 2 times in a post, the first one can be clicked and expands to show the footnote, but the second does not (nor does the third…).
  • reproduced on my site with the minimal example provided on the Discourse footnote post :

We are our choices. [1]
A lot of interesting words
He really said it. [1:1]

  • Tried to reproduce on try.discourse.org but the footnote plugin does not seem available

Can someone reproduce as well or is there a problem with my site ?


  1. We are our choices.
    Sartre, some time
    some day
    in the past ↩︎ ↩︎

1 个赞

I’ve tested that example on my local dev site (running the latest Discourse code with the Chrome browser.) I’m finding that the second footnote is positioned either at the bottom of the page, or off the page.

If I try inserting a unique footnote between the two duplicate footnotes, the second of the duplicate footnotes will display the content of the unique footnote if it is clicked after having clicked the unique footnote. Example markup for that issue:

We are our choices. [^sartre]

A lot of interesting words

Second footnote test [^second]

He really said it. [^sartre]

[^sartre]: We are our choices.
Sartre, some time
some day
in the past

[^second]: this is the content of the second footnote

2 个赞

我今天遇到了这个,试图幽默一下[1]


  1. 你可以读这个,但你不能展开这个[2]↩︎

  2. 真可惜!这太搞笑了。 ↩︎

我猜这个 Discourse 没有使用脚注插件。

所以……我推断这是否能正常工作取决于我。是这样吗?有人能帮我一把吗?

第一步是弄清楚它是否在这里工作:

我们只是重新打包它,有可能它已经在最新版本中得到了改进。

1 个赞

我终于有时间研究这个问题了。感谢您的建议。

markdown-itmarkdown-it-footnote 的行为符合我的预期。我通过一些简单的单元测试确认了这一点。

当我尝试点击主题中的脚注时,问题似乎出现了。以下是我的情况。

首先,我尝试点击嵌套脚注中的“…”,这会重新加载页面;然后我尝试点击嵌套脚注中的“[2]”链接,但没有相应的 HTML 锚点。

我该如何解决这个问题?

非常感谢。

1 个赞