Compare commits

..

No commits in common. "e4d0ed94c17e54d1cdd73e2bff33de41fea7144a" and "aae7b8476aa8fd4cc25744e9708adf524a7bfacb" have entirely different histories.

10 changed files with 37 additions and 45 deletions

View File

@ -1,14 +1,12 @@
// Installed Plugins // Installed Plugins
import pluginRss from "@11ty/eleventy-plugin-rss"; const pluginRss = require("@11ty/eleventy-plugin-rss");
import eleventyNavigationPlugin from "@11ty/eleventy-navigation"; const eleventyNavigationPlugin = require("@11ty/eleventy-navigation");
import metagen from 'eleventy-plugin-metagen'; const metagen = require('eleventy-plugin-metagen');
import emojiReadTime from "@11tyrocks/eleventy-plugin-emoji-readtime"; const emojiReadTime = require("@11tyrocks/eleventy-plugin-emoji-readtime");
import slugify from "slugify"; const slugify = require("slugify");
import markdownPlugin from "./eleventy.config.md.js"; module.exports = function (eleventyConfig) {
export default function (eleventyConfig) {
// Copy files // Copy files
eleventyConfig.addPassthroughCopy("./src/assets/"); eleventyConfig.addPassthroughCopy("./src/assets/");
eleventyConfig.addWatchTarget("./src/assets/"); eleventyConfig.addWatchTarget("./src/assets/");
@ -17,7 +15,7 @@ export default function (eleventyConfig) {
}); });
// Custom Plugins // Custom Plugins
eleventyConfig.addPlugin(markdownPlugin); eleventyConfig.addPlugin(require('./eleventy.config.md.js'));
// Installed Plugins // Installed Plugins
eleventyConfig.addPlugin(pluginRss); eleventyConfig.addPlugin(pluginRss);
@ -27,7 +25,7 @@ export default function (eleventyConfig) {
// Eleventy bundle plugin // Eleventy bundle plugin
eleventyConfig.addBundle("css"); eleventyConfig.addBundle("css");
eleventyConfig.addBundle("js", { toFileDirectory: "assets/js" }); eleventyConfig.addBundle("js");
// Add content categories to a collection // Add content categories to a collection
eleventyConfig.addCollection("categories", function(collectionApi) { eleventyConfig.addCollection("categories", function(collectionApi) {

View File

@ -1,22 +1,16 @@
/* CONFIGURATION FOR MARKDOWN TEMPLATES */ /* CONFIGURATION FOR MARKDOWN TEMPLATES */
// Installed Plugins // Installed Plugins
import pluginTOC from '@uncenter/eleventy-plugin-toc'; const pluginTOC = require('@uncenter/eleventy-plugin-toc');
import embedEverything from "eleventy-plugin-embed-everything"; const embedEverything = require("eleventy-plugin-embed-everything");
// Configure slug filter // Configure slug filter
import slugify from "slugify"; const slugify = require("slugify");
// Configure markdown-it plugins
const markdownIt = require("markdown-it");
const markdownItAnchor = require("markdown-it-anchor");
// markdown-it plugins module.exports = function (eleventyConfig) {
import markdownIt from "markdown-it";
import markdownItAnchor from "markdown-it-anchor";
import markdownItAttribution from "markdown-it-attribution";
import markdownItAttrs from "markdown-it-attrs";
import markdownItBracketedSpans from 'markdown-it-bracketed-spans';
import markdownItDefList from "markdown-it-deflist";
import markdownItFootnote from "markdown-it-footnote";
export default function (eleventyConfig) {
// Installed Plugins // Installed Plugins
eleventyConfig.addPlugin(pluginTOC, { eleventyConfig.addPlugin(pluginTOC, {
tags: ['h2', 'h3', 'h4', 'h5', 'h6'], tags: ['h2', 'h3', 'h4', 'h5', 'h6'],
@ -79,11 +73,11 @@ export default function (eleventyConfig) {
linkify: true, linkify: true,
}) })
.use(markdownItAnchor, markdownItAnchorOptions) .use(markdownItAnchor, markdownItAnchorOptions)
.use(markdownItAttribution) .use(require("markdown-it-attribution"))
.use(markdownItAttrs) .use(require("markdown-it-attrs"))
.use(markdownItBracketedSpans) .use(require("markdown-it-bracketed-spans"))
.use(markdownItDefList) .use(require("markdown-it-deflist"))
.use(markdownItFootnote); .use(require('markdown-it-footnote'));
// Configure linkify // Configure linkify
markdownLibrary.linkify.set({ fuzzyLink: false }); markdownLibrary.linkify.set({ fuzzyLink: false });

View File

@ -4,7 +4,6 @@
"start": "bunx @11ty/eleventy --serve --quiet", "start": "bunx @11ty/eleventy --serve --quiet",
"build": "bunx @11ty/eleventy" "build": "bunx @11ty/eleventy"
}, },
"type": "module",
"devDependencies": { "devDependencies": {
"@types/bun": "^1.1.6" "@types/bun": "^1.1.6"
}, },

View File

@ -1,11 +1,13 @@
export const siteName = "Leilukin's Hub"; module.exports = {
export const siteDomain = "leilukin.com"; siteName: "Leilukin's Hub",
export const siteUrl = "https://" + siteDomain || "http://localhost:8080"; siteUrl: "https://leilukin.com" || "http://localhost:8080",
export const siteAuthor = { siteDomain: "leilukin.com",
name: "Leilukin", siteLocale: "en_MY",
email: "contact@leilukin.com", siteLanguage: "en",
url: siteUrl + "/about" siteDescription: "Leilukin's personal website.",
}; siteAuthor: {
export const siteLocale = "en_MY"; name: "Leilukin",
export const siteLanguage = "en"; email: "contact@leilukin.com",
export const siteDescription = siteAuthor.name + "'s personal website."; url: this.siteUrl + "/about"
}
}

View File

@ -2,7 +2,6 @@
desc=desc or metadata.desc, desc=desc or metadata.desc,
url=sitemeta.siteUrl + page.url, url=sitemeta.siteUrl + page.url,
locale=sitemeta.siteLocale, locale=sitemeta.siteLocale,
name=sitemeta.siteAuthor.name,
site_name=sitemeta.siteName, site_name=sitemeta.siteName,
img=image, img=image,
img_alt=alt, img_alt=alt,

View File

@ -5,10 +5,10 @@ eleventyNavigation:
eleventyComputed: eleventyComputed:
desc: Leave a message for {{ sitemeta.siteAuthor.name }}. desc: Leave a message for {{ sitemeta.siteAuthor.name }}.
--- ---
{%- css %}{% include "src/_bundle/css/comments.css" %}{%- endcss %} {%- css %}{% include "src/assets/css/comments.css" %}{%- endcss %}
{%- js %}{% include "src/_bundle/js/svgIconControl.js" %}{%- endjs %} {%- js %}{% include "src/assets/js/svgIconControl.js" %}{%- endjs %}
{%- js %}{% include "src/_bundle/js/googleSheetsReaderGizmo.js" %}{%- endjs %} {%- js %}{% include "src/assets/js/googleSheetsReaderGizmo.js" %}{%- endjs %}
{%- js %}{% include "src/_bundle/js/comments.js" %}{%- endjs %} {%- js %}{% include "src/assets/js/comments.js" %}{%- endjs %}
<p class="center-text">Guestbook Archive: <a href="https://web.archive.org/web/20240528231121/https%3A%2F%2Fleilukin.123guestbook.com%2F">123Guestbook</a></p> <p class="center-text">Guestbook Archive: <a href="https://web.archive.org/web/20240528231121/https%3A%2F%2Fleilukin.123guestbook.com%2F">123Guestbook</a></p>