Skip to content

Commit

Permalink
🐛 新增仅注解变量生成变量文档
Browse files Browse the repository at this point in the history
  • Loading branch information
snowykami committed Aug 29, 2024
1 parent c804188 commit 9ed63a8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion litedoc/style/markdown.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ def generate(parser: AstParser, lang: str, frontmatter: Optional[dict] = None, s

"""遍历函数"""
for func in parser.functions:
if func.name.startswith("_"):
# 仅给有注释的函数生成文档
if func.name.startswith("_") or func.docs is None:
continue
md += func.markdown(lang)

Expand Down

0 comments on commit 9ed63a8

Please sign in to comment.