Fixed rehype-figure
This commit is contained in:
parent
ccd3f51779
commit
4b30fd0d79
1 changed files with 4 additions and 7 deletions
|
@ -1,14 +1,15 @@
|
||||||
import { defineConfig } from 'astro/config';
|
import { defineConfig } from 'astro/config';
|
||||||
|
|
||||||
import compress from "astro-compress";
|
import compress from "astro-compress";
|
||||||
|
|
||||||
import remarkPostMeta from './remark-post-meta.mjs';
|
import remarkPostMeta from './remark-post-meta.mjs';
|
||||||
import remarkUnwrapImages from 'remark-unwrap-images';
|
|
||||||
import { rehypeHeadingIds } from '@astrojs/markdown-remark';
|
import { rehypeHeadingIds } from '@astrojs/markdown-remark';
|
||||||
import rehypeSlug from 'rehype-slug';
|
import rehypeSlug from 'rehype-slug';
|
||||||
import rehypeAutolinkHeadings from 'rehype-autolink-headings';
|
import rehypeAutolinkHeadings from 'rehype-autolink-headings';
|
||||||
|
|
||||||
import rehypeFigure from 'rehype-figure';
|
import rehypeFigure from 'rehype-figure';
|
||||||
|
|
||||||
// https://astro.build/config
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
integrations: [compress()],
|
integrations: [compress()],
|
||||||
build: {
|
build: {
|
||||||
|
@ -18,7 +19,6 @@ export default defineConfig({
|
||||||
syntaxHighlight: "shiki",
|
syntaxHighlight: "shiki",
|
||||||
remarkPlugins: [
|
remarkPlugins: [
|
||||||
remarkPostMeta,
|
remarkPostMeta,
|
||||||
remarkUnwrapImages,
|
|
||||||
],
|
],
|
||||||
rehypePlugins: [
|
rehypePlugins: [
|
||||||
rehypeSlug,
|
rehypeSlug,
|
||||||
|
@ -27,10 +27,7 @@ export default defineConfig({
|
||||||
rehypeAutolinkHeadings,
|
rehypeAutolinkHeadings,
|
||||||
{ behavior: "append" },
|
{ behavior: "append" },
|
||||||
],
|
],
|
||||||
[
|
|
||||||
rehypeFigure,
|
rehypeFigure,
|
||||||
{ className: "rehype-figure" },
|
|
||||||
],
|
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
});
|
});
|
Loading…
Add table
Reference in a new issue