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);