From 9875912ff6b0a707b0920f9adc8e73529cbb9d53 Mon Sep 17 00:00:00 2001 From: Zach Leatherman Date: Thu, 2 Feb 2023 15:30:07 -0600 Subject: [PATCH] Add transforms example --- README.md | 26 ++++++++++++++++++++ codeManager.js | 1 + test/stubs/use-transforms/eleventy.config.js | 2 +- 3 files changed, 28 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 6597701..1647f8b 100644 --- a/README.md +++ b/README.md @@ -47,6 +47,10 @@ module.exports = function(eleventyConfig) { // Default bundle types bundles: ["css", "js", "html"], + + // Array of async-friendly callbacks to transform bundle content. + // Works with getBundle and getBundleFileUrl + transforms: [] }); }; ``` @@ -248,6 +252,28 @@ To add JS to a page bundle in WebC, you would use a `