From 204a1b46ca7e3898dae0a8dd933c717c5c321157 Mon Sep 17 00:00:00 2001 From: Nexan Date: Wed, 31 Jan 2024 10:33:44 -0600 Subject: [PATCH] major Readme update --- .eleventy.js | 26 ++++++++++++++++++++++++++ readme.md | 11 +++++++++++ 2 files changed, 37 insertions(+) create mode 100644 .eleventy.js create mode 100644 readme.md diff --git a/.eleventy.js b/.eleventy.js new file mode 100644 index 0000000..f8b41f0 --- /dev/null +++ b/.eleventy.js @@ -0,0 +1,26 @@ +const syntaxHighlight = require('@11ty/eleventy-plugin-syntaxhighlight') +const markdownIt = require('markdown-it') +const markdownItAnchor = require('markdown-it-anchor') + +module.exports = function(eleventyConfig) { + // Copy these static files to _site folder + eleventyConfig.addPassthroughCopy('src/assets') + eleventyConfig.addPassthroughCopy('src/manifest.json') + + const md = markdownIt({ html: true, linkify: true }) + md.use(markdownItAnchor, { + level: [1, 2], + permalink: markdownItAnchor.permalink.headerLink({ + safariReaderFix: true, + class: 'header-anchor', + }) + }) + eleventyConfig.setLibrary('md', md) + + return { + markdownTemplateEngine: 'liquid', + dir: { + input: 'src' + } + } +} \ No newline at end of file diff --git a/readme.md b/readme.md new file mode 100644 index 0000000..4dfa557 --- /dev/null +++ b/readme.md @@ -0,0 +1,11 @@ +# Eleventy Template by Nexan + +This is a template kit for me to potentially use for building barebones sites using Eleventy. + +In terms of what functions this will have by default, I plan to have an auto-built Sitemap.xml file, a 404 Page, and a few other things to be determined later. + +Files being worked on live in `/src/`, while output will live in `/_site` once built. + +Pre-made scripts for NPM include `start` and `build` which run a development version of the site, and build the site for publishing, respectively. More scripts may be added later as I find them useful. + +Templating is done in Liquid, pages can be made in any language available to Eleventy, though they will mostly be Markdown or HTML, or a combination of the two.