是否有比 kramdown 更快且仍使用 PHP Markdown 语法的替代方案?

发布于 2024-12-27 12:16:51 字数 374 浏览 2 评论 0原文

我刚刚将我的网站移至 Octopress,它预先配置了 rdiscount Markdown 解析器,但我的档案中有很多用 PHP Markdown 额外 语法。我需要的主要语法是脚注:

This is my sentence.[^1]

[^1]: This is my footnote.

Kramdown 可以做到这一点,但它会减慢网站的生成速度。据我所知,rediscount 是迄今为止最快的解析器,但它不处理这个脚注语法。是否有其他更快的并且内置了这种语法?非常感谢。

I just moved my site to Octopress, which comes preconfigured with the rdiscount Markdown parser, but my archives have a lot of posts that were written with the PHP Markdown Extra syntax. The main syntax I need is for footnotes:

This is my sentence.[^1]

[^1]: This is my footnote.

Kramdown does it, but it's slowing down site generation. As far as I understand rediscount is by far the fastest parser, but it doesn't handle this footnote syntax. Are there others that are faster and have this syntax built in? Thanks so much.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

执妄 2025-01-03 12:16:51

Octopress 使用 Jekyll,它有 3 个 markdown 参数:

  • rdiscount
  • kramdown
  • maruku

看来你已经尝试过前两个,但没有尝试过第三。我已经查看了其规格并且它似乎支持脚注。不过,我不知道它比 rdiscount 更快还是更慢。

最好的选择就是尝试一下。如果它有效,那么这就是你的选择。如果没有,那就没有其他选择了。

Octopress uses Jekyll, which has 3 markdown parameters:

  • rdiscount
  • kramdown
  • maruku

It seems that you have tried the first two, but not the third. I've given a look at its specs and it seems to support footnotes. I don't know whether it's faster or slower than rdiscount, though.

Best option is to try it. If it works, then that's your option. If not, then there is no other alternative.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文