Add remark-toc plugin.
Add plugin for generating table of content automatically for markdown files.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { defineConfig } from 'astro/config';
|
||||
import sitemap from "@astrojs/sitemap";
|
||||
import vue from "@astrojs/vue";
|
||||
import remarkToc from 'remark-toc';
|
||||
|
||||
// https://astro.build/config
|
||||
export default defineConfig({
|
||||
@@ -26,7 +27,10 @@ export default defineConfig({
|
||||
// Add custom transformers: https://shiki.style/guide/transformers
|
||||
// Find common transformers: https://shiki.style/packages/transformers
|
||||
transformers: []
|
||||
}
|
||||
},
|
||||
remarkPlugins: [
|
||||
[remarkToc, { heading: "(table[ -]of[ -])?contents?|toc|目录" }]
|
||||
],
|
||||
},
|
||||
site: 'https://lishouzhong.com',
|
||||
integrations: [
|
||||
|
||||
Reference in New Issue
Block a user