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

关于元素 ID 改变的一个修复建议 #1

Open
LeafYeeXYZ opened this issue Jul 14, 2024 · 1 comment
Open

关于元素 ID 改变的一个修复建议 #1

LeafYeeXYZ opened this issue Jul 14, 2024 · 1 comment

Comments

@LeafYeeXYZ
Copy link

可以使用一个空元素作为新的锚点

例如,假如原内容是:

## Question/Element Types

翻译后可以修改为:

## 问题/元素的类型<span id="questionelement-types"></span>

这样就不用一个个修改指向这个标题的链接了

@Shaobin-Jiang
Copy link
Owner

我很早之前尝试的做法是使用 <h2 id="questionelement-types"></h2> 这种形式,但是这么做还是得先把文档生成出来去查看标题的 id(我对 mkdocs 没有那么熟)。后来放弃这个做法也是因为一个一个查找太麻烦了,相比起来还是修改链接工作量小一点……

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

No branches or pull requests

2 participants