diff --git a/src/components/CodeBlock.astro b/src/components/CodeBlock.astro new file mode 100644 index 0000000..bf8f19e --- /dev/null +++ b/src/components/CodeBlock.astro @@ -0,0 +1,48 @@ +--- +import { Code } from 'astro:components'; + +interface Props { + code: string; + lang: string; + wrap?: boolean; + inline?: boolean; + /** Shiki theme for light mode */ + lightTheme?: string; + /** Shiki theme for dark mode */ + darkTheme?: string; +} + +const { + code, + lang, + wrap = false, + inline = false, + lightTheme = 'min-light', + darkTheme = 'night-owl', +} = Astro.props as Props; +--- + +
+ + + + +