Proposal: auto generate sidebar
维护者通常 8 天内回复
@sy-records 已经在做这个了。
开始于 2025年7月28日。
评估
这个 Issue 还没有评估数据。
描述
Auto-generate sidebar
Summary
Auto-generate and update the sidebar i.e _sidebar.md by looking into the folders/files
Motivation
If you have a big project or a project having many markdown files. It is kind of extra work look for each file and writes the path and the file name and the text to display it.
Maximum projects I have seen take each .md file as a single page and .md files under a folder inside the docs directory is a sub-page. So if we go with usual lookups through each file/folder. This is quite easy to achieve.
Detailed Design
No changes are required in the core. Only needs changes in cli. New command probably
If we have directories like this
|- <root>
|- README.md
|- index.html
|- _sidebar.md
|- a.md
|- guide
|- guide-a.md
|- b.md
The sidebar command should generate the following
- [a](./a.md)
- guide
- [a](./guide/guide-a.md)
- [b](./b.md)
We need to traverse through the directory and create an object or tree and then just print the tree as a list in the markdown.
Documentation
Update the docs in the main docs site as a separate page and create docs for the command in the cli and do a remote rendering of the page in the main docs
Drawbacks
Few
- It won't know whether markdown file should be in the heading or in subheading if it goes out of our prediction.
- cant do the operation for the
.htmlfiles.
Backwards Compatibility Analysis
Not required as no changes in the core is being done.
Alternatives
Do the manual entry in the _sidebar.md
Open Questions
- Should we wait for or put this in
v5? - Any volunteers for taking this ?
Help Needed
None.
Frequently Asked Questions
None
Related Discussions
Couldnt find any.
- 主要语言
- JavaScript
- 星标
- 31.5k
- 派生
- 5.8k
- 平均合并
- 7 天 18 小时
- 30 天内合并 PR
- 9
环境准备
- 提供 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
docsifyjs/docsify 的其他 Issue
-
Query parameter values are truncated at a second equals sign可能已有人在做 @xu91102 于 23 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 88/100
维护者通常 8 天内回复
-
bug Triage
难度 3/5 1-2 天 新手友好度 66/100
维护者通常 8 天内回复
-
Cached AJAX responses lose status metadata exposed through vm.route.response可能已有人在做 @xu91102 于 23 天前认领。 未关闭
难度 3/5 1-2 天 新手友好度 68/100
维护者通常 8 天内回复
-
In the Edge browser, the character `{docsify-updated}` is not replaced可能重新可做 @AmanUllah687 于 76 天前认领,目前没有进行中的 PR。 未关闭wait for information
难度 4/5 3-5 天 新手友好度 35/100
docsifyjs/docsify#2681 · 11 条评论 ·
维护者通常 8 天内回复
-
feature request Triage
难度 4/5 3-5 天 新手友好度 38/100
docsifyjs/docsify#2643 · 5 条评论 ·
维护者通常 8 天内回复
查看 docsifyjs/docsify 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 72/100
subhranshudash13-dotcom/Contribo#74 ·
维护者通常 1 天内回复
-
enhancement
难度 2/5 1-3 小时 新手友好度 62/100
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 67/100
ThatGuySam/doesitarm#1114 ·
-
enhancement good first issue
难度 2/5 1-3 小时 新手友好度 85/100
laaielichter/Reverseport#44 ·
维护者通常 1 天内回复
-
failed for an unknown reason
难度 2/5 1-3 小时 新手友好度 65/100
OpenTermsArchive/contrib-declarations#4148 ·
维护者通常 1 天内回复