-
Notifications
You must be signed in to change notification settings - Fork 2
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
Referencing formula numbers in articles #34
Comments
simply and ugly workaround....
|
Thanks to your solution. I use katex's marco function and wrap it up with elegant code. trust: (context) => ['\\htmlId', '\\href'].includes(context.command),
macros: {
"\\eqref": "\\href{###1}{(\\text{#1})}",
"\\ref": "\\href{###1}{\\text{#1}}",
"\\label": "\\htmlId{#1}{}"
} Then you can use more details: https://column.mowchan.me/post/2021/katex-ref-label-support.html |
@zhangpeng96 你好,不知有时间可以写一个 vs code 插件 markdowm+math(不是 markdown math)的配置文件吗,资料看了半天没有搞好,谢谢了。 } |
markdowm是什么?是markdown打错了吗?关于katex的配置可以看官方的文档:https://github.com/KaTeX/KaTeX/blob/master/docs/options.md vscode插件编写我不了解,没办法帮你 |
安装vscode插件: [Markdown+Math],并在vscode配置文件里添加如下设置,即可渲染\label、\ref、\eqref "mdmath.katexoptions": {
"trust": "(context) => ['\\htmlId', '\\href'].includes(context.command)"
},
"mdmath.macros": {
"\\eqref": "\\href{###1}{(\\text{#1})}",
"\\ref": "\\href{###1}{\\text{#1}}",
"\\label": "\\htmlId{#1}{}"
}, 本方法参考这个帖子。 |
The expression number is inserted directly in the article, but it should be expressed by
\label
,\ref
,\eqref
, etc.However, KaTeX (0.12.0) does not currently support them, so this is not feasible. If this is implemented, we plan to introduce it sequentially. (This was possible because the old blog used mathjax).
The text was updated successfully, but these errors were encountered: