πŸ‡ΊπŸ‡¦πŸ‡ΊπŸ‡¦πŸ‡ΊπŸ‡¦ Stand with Ukraine πŸ‡ΊπŸ‡¦πŸ‡ΊπŸ‡¦πŸ‡ΊπŸ‡¦
Eleventy
The possum is Eleventy’s mascot
Eleventy Documentation
Menu
Eleventy 5.81s
Gatsby 43.36s

Directory Output

Contents

Group and sort Eleventy’s verbose output by directory (and show file size with benchmarks). View the source code on GitHub.

Installation Jump to heading

npm install @11ty/eleventy-plugin-directory-output

Open up your Eleventy config file (probably .eleventy.js) and use addPlugin:

Filename .eleventy.js
const directoryOutputPlugin = require("@11ty/eleventy-plugin-directory-output");

module.exports = function(eleventyConfig) {
eleventyConfig.setQuietMode(true);
eleventyConfig.addPlugin(directoryOutputPlugin);
};
INFO:
You’re only allowed one module.exports in your configuration file, so make sure you only copy the require and the addPlugin lines above!

Read more about Eleventy plugins.

Options Jump to heading

const directoryOutputPlugin = require("@11ty/eleventy-plugin-directory-output");

module.exports = function(eleventyConfig) {
eleventyConfig.setQuietMode(true);
eleventyConfig.addPlugin(directoryOutputPlugin, {
// Customize columns
columns: {
filesize: true, // Use `false` to disable
benchmark: true, // Use `false` to disable
},

// Will show in yellow if greater than this number of bytes
warningFileSize: 400 * 1000,
});
};
INFO:
The benchmark column is only compatible with Eleventy 1.0.1 or newer.

Sample Output Jump to heading

> eleventy-base-blog@6.0.0 build
> eleventy

β†˜ _site/ -- -- --
β†’ about/index.html about/index.md 1.8kB 2.7ms
β†˜ feed/ -- -- --
β€’ .htaccess feed/htaccess.njk 0.1kB 0.2ms
β€’ feed.json feed/json.njk 106.8kB 17.3ms
β€’ feed.xml feed/feed.njk 109.8kB 9.8ms
β†’ page-list/index.html page-list.njk 3.2kB 1.1ms
β†˜ posts/ -- -- --
β†’ firstpost/index.html posts/firstpost.md 3.5kB 1.0ms
β†’ fourthpost/index.html posts/fourthpost.md 101.0kB 27.2ms
β†’ secondpost/index.html posts/secondpost.md 3.2kB 5.6ms
β†’ thirdpost/index.html posts/thirdpost.md 4.5kB 7.5ms
β€’ index.html archive.njk 3.0kB 13.7ms
β†˜ tags/ -- -- --
β†’ another-tag/index.html tags.njk 2.1kB 0.9ms
β†’ number-2/index.html tags.njk 2.1kB 0.4ms
β†’ posts-with-two-tags/index.html tags.njk 2.3kB 0.2ms
β†’ second-tag/index.html tags.njk 2.5kB 0.5ms
β€’ index.html tags-list.njk 2.0kB 0.4ms
β€’ 404.html 404.md 1.9kB 0.4ms
β€’ index.html index.njk 2.8kB 1.7ms
β€’ sitemap.xml sitemap.xml.njk 1.4kB 1.3ms
[11ty] Copied 3 files / Wrote 18 files in 0.16 seconds (8.9ms each, v1.0.1)

Other pages in Plugins: