项目参考
本项目在开发过程中参考了多个优秀的开源项目,以下是主要的参考来源:
Mister-Hope 的 VuePress 主题
Mister-Hope 的 VitePress 主题是本项目最重要的参考来源之一。
本项目在开发过程中参考了多个优秀的开源项目,以下是主要的参考来源:
Mister-Hope 的 VitePress 主题是本项目最重要的参考来源之一。
自定义内容对齐方式。
import { defineConfig } from 'vitepress-theme-niansi'
export default defineConfig({
markdown: {
plugins: {
align: true
}
}
})
主题为你提供预览支持。
import { defineConfig } from 'vitepress-theme-niansi'
export default defineConfig({
markdown: {
plugins: {
preview: true
}
}
})
让你的 VitePress 站点中的图片支持尺寸标注、懒加载、图片包裹等功能。
import { defineConfig } from 'vitepress-theme-niansi'
export default defineConfig({
markdown: {
// 懒加载(可选)
image: {
lazyLoading: true
},
plugins: {
// 开启图片插件
image: true
// 或传入配置项
// image: { lazyLoading: true, focusable: false, linkImage: false }
}
}
})
统一的内联语法工厂工具函数,用于创建基于标点符号的自定义内联标签。
import { defineConfig, inlineRule } from 'vitepress-theme-niansi'
export default defineConfig({
markdown: {
config(md) {
md.use(inlineRule, {
marker: "~",
tag: "sub",
token: "sub",
})
}
}
})
让你的 VitePress 站点中的 Markdown 文件支持标记。
import { defineConfig } from 'vitepress-theme-niansi'
export default defineConfig({
markdown: {
plugins: {
mark: true
}
}
})
在你的 VitePress 站点中添加剧透文字。
import { defineConfig } from 'vitepress-theme-niansi'
export default defineConfig({
markdown: {
plugins: {
spoiler: true
}
}
})
让你的 VitePress 站点中的 Markdown 文件支持上下角标。
import { defineConfig } from 'vitepress-theme-niansi'
export default defineConfig({
markdown: {
plugins: {
// 启用下角标
sub: true,
// 启用上角标
sup: true
}
}
})
让你的 VitePress 站点中的 Markdown 文件支持任务列表。
import { defineConfig } from 'vitepress-theme-niansi'
export default defineConfig({
markdown: {
plugins: {
tasklist: true
}
}
})