Skip to content

pantoken / plugins/typedoc/demo/src / rewriteComment

函数: rewriteComment()

rewriteComment(comment): void

Beta

将注释中每个 @demo 块标签按顺序移入附加到其摘要的 demo 围栏中。 块标签内容会被 Markdown 主题重新加围栏,所以围栏必须位于摘要 正文中,该正文按原样输出。

参数

comment

Comment

要就地重写的注释。

返回值

void

示例

ts
import { rewriteComment } from "@pantoken/typedoc-plugin-demo";

// Given a comment with `@demo self:button`, appends a ```demo``` fence and drops the tag.
rewriteComment(comment);