unifast
  • 什么是 unifast?
  • 快速开始
  • 核心概念
  • React 集成
  • Vite 集成
  • 使用 MDX
  • 语法高亮
软件包
  • escapeHtml()
  • extractLang()
  • extractText()
  • findCodeChild()
  • hastToHtml()
  • visitHast()
  • abbr()
  • accessibleEmoji()
  • addClasses()
  • autolinkHeadings()
  • breaks()
  • cjk()
  • codeImport()
  • codeMeta()
  • commentRemoval()
  • compile()
  • customHeadingId()
  • definitionList()
  • directive()
  • emoji()
  • excerpt()
  • externalLinks()
  • figure()
  • frontmatter()
  • gfm()
  • githubAlert()
  • imgLazyLoading()
  • math()
  • minify()
  • readingTime()
  • rubyAnnotation()
  • sanitize()
  • sectionize()
  • smartypants()
  • syntect()
  • toc()
  • treeSitter()
  • wikiLink()
  • createShikiPlugin()
  • createShikiTransformer()
  • highlight()
  • unifastPlugin()
  • compileToReact()
  • hastToReact()

githubAlert()

在引用块中支持 GitHub 风格的提示块(NOTE、TIP、WARNING 等)。

import { githubAlert } from "@unifast/node";

签名

function githubAlert(): UnifastPlugin

参数

无。

用法

import { compile, githubAlert } from "@unifast/node";

const result = compile(md, {
  plugins: [githubAlert()],
});

示例

GitHub 风格的提示块

编辑此页
上一页gfm()下一页math()

Made with ❤️ by Kenzo Wada

On this page
  • 签名
  • 参数
  • 用法
  • 示例
  • GitHub 风格的提示块