diff options
Diffstat (limited to 'eleventy.config.mjs')
| -rw-r--r-- | eleventy.config.mjs | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/eleventy.config.mjs b/eleventy.config.mjs index 2e679a3..d81c29a 100644 --- a/eleventy.config.mjs +++ b/eleventy.config.mjs @@ -1,7 +1,8 @@ import { parseISO , format} from "date-fns"; import { config as siteConfig } from "./siteconfig.mjs"; import { eleventyImageTransformPlugin } from "@11ty/eleventy-img"; - +import EleventyPluginOgImage from 'eleventy-plugin-og-image'; +import fs from "fs" export default function(eleventyConfig) { // Order matters, put this at the top of your configuration file. @@ -18,6 +19,25 @@ export default function(eleventyConfig) { }); }); + eleventyConfig.addPlugin(EleventyPluginOgImage, { + satoriOptions: { + fonts: [ + { + name: 'JetBrains Mono', + data: fs.readFileSync('./assets/fonts/JetBrains/OG-Regular.ttf'), + weight: 400, + style: 'normal', + }, + { + name: 'JetBrains Mono', + data: fs.readFileSync('./assets/fonts/JetBrains/OG-Bold.ttf'), + weight: 800, + style: 'normal', + }, + ], + }, + }); + eleventyConfig.addPlugin(eleventyImageTransformPlugin, { widths: [200, "auto"], htmlOptions: { |
