⚙️ Update svelte.config to use `makeSingletonHighlighter` for shiki

This commit is contained in:
pheralb 2024-08-20 19:28:35 +01:00
parent 9080802c3e
commit bcc2d48bf6

View File

@ -3,7 +3,9 @@ import { vitePreprocess } from '@sveltejs/vite-plugin-svelte';
// Extensions:
import { mdsvex, escapeSvelte } from 'mdsvex';
import { getHighlighter } from 'shiki';
import { createHighlighter, makeSingletonHighlighter } from 'shiki';
const getHighlighter = makeSingletonHighlighter(createHighlighter);
// Markdown config:
/** @type {import('mdsvex').MdsvexOptions} */