There are two types of markup in Liquid: Output and Tag.
- Output markup (which may resolve to text) is surrounded by
{{ matched pairs of curly brackets (ie, braces) }}- Tag markup (which cannot resolve to text) is surrounded by
| // This file goes in /src/transforms/ | |
| // Add this line to .eleventy.js: | |
| // const eleventyImgTransform = require("./src/transforms/eleventy-img-transform.js"); | |
| // And add this one to module.exports in .eleventy.js: | |
| // eleventyConfig.addTransform("eleventyImgTransform", eleventyImgTransform); | |
| const Image = require("@11ty/eleventy-img"); | |
| const cheerio = require("cheerio"); |
There are two types of markup in Liquid: Output and Tag.
{{ matched pairs of curly brackets (ie, braces) }}