From eb567ec6a36145d1c88b81a15d74ec16b2a559e2 Mon Sep 17 00:00:00 2001 From: Alexis Hovorka Date: Fri, 16 Aug 2024 23:09:44 -0600 Subject: [chore] Dust off some outdated dependencies --- .eleventy.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to '.eleventy.js') diff --git a/.eleventy.js b/.eleventy.js index 2ffec7d..6cb78a0 100644 --- a/.eleventy.js +++ b/.eleventy.js @@ -5,7 +5,11 @@ const { DateTime } = require("luxon"); const utils = require("markdown-it/lib/common/utils"); const excerptMinimumLength = 280; -const excerptSeparator = "" +const excerptSeparator = ""; + +const twemojiOpts = { + base: "https://cdnjs.cloudflare.com/ajax/libs/twemoji/15.1.0/", +}; function extractExcerpt(doc) { if (doc.data.readOnline) return "[[ No Excerpt Available ]]"; @@ -66,7 +70,7 @@ module.exports = (cfg) => { md.renderer.rules.emoji = (token, i) => `${twemoji.parse(token[i].content)}`; + `title="${token[i].markup}">${twemoji.parse(token[i].content, twemojiOpts)}`; md.renderer.rules.code_block = (tokens, i, options, env, slf) => `` + utils.escapeHtml(tokens[i].content.replace(/ /g, "\xA0"))+'\n'; -- cgit v1.2.3-70-g09d2