From 1fc25997a7d4b3cf80dbc09a3f48afd031ba5d0e Mon Sep 17 00:00:00 2001 From: Jan Palma Date: Fri, 27 Feb 2026 17:59:06 +0100 Subject: Init --- eleventy.config.mjs | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 eleventy.config.mjs (limited to 'eleventy.config.mjs') diff --git a/eleventy.config.mjs b/eleventy.config.mjs new file mode 100644 index 0000000..086ca13 --- /dev/null +++ b/eleventy.config.mjs @@ -0,0 +1,31 @@ +import { parseISO , format} from "date-fns"; +import { config as siteConfig } from "./siteconfig.mjs"; + + +export default function(eleventyConfig) { + // Order matters, put this at the top of your configuration file. + + eleventyConfig.addNunjucksFilter("date", (dateObj, formatString = 'MM.dd.yyyy') => format(dateObj, formatString)) + + eleventyConfig.addGlobalData("layout","page"); + eleventyConfig.addGlobalData("site", { + title: siteConfig.siteTitle ?? "Site", + socials: siteConfig.socials + }) + + eleventyConfig + .addPassthroughCopy({"./public/": "/"}) + .addPassthroughCopy({"./assets/": "/assets"}) + +}; +export const config = { + dir: { + input: "content", + output: "_dist", + includes: "../_includes", + layouts: "../_layouts", + }, + templateFormats: ["md", "njk"], + htmlTemplateEngine: "njk", + markdownTemplateEngine: "njk" +}; \ No newline at end of file -- cgit v1.3-7-ge9ab