install some stuff for 11ty

markdown attributes
configure eleventy renderFile plugin
This commit is contained in:
2023-10-12 22:35:08 +05:30
parent 93bc2187b6
commit ac4e71106b
3 changed files with 280 additions and 50 deletions

View File

@@ -1,8 +1,14 @@
const { EleventyHtmlBasePlugin } = require("@11ty/eleventy");
const { EleventyHtmlBasePlugin, EleventyRenderPlugin } = require("@11ty/eleventy");
const markdownItAttrs = require("markdown-it-attrs");
module.exports = function(eleventyConfig){
eleventyConfig.addPlugin(EleventyHtmlBasePlugin);
eleventyConfig.addPlugin(EleventyRenderPlugin);
eleventyConfig.amendLibrary("md", mdLib => mdLib.use(markdownItAttrs));
eleventyConfig.addPassthroughCopy("static");
return {
pathPrefix: "/",
dir: {