The Equal Justice Initiative
The possum is Eleventy’s mascot

Eleventy Documentation

This is an older version of Eleventy. Go to the newest Eleventy docs (current path: /docs/languages/mustache/) or the full release history.


Template Languages:

Eleventy Short NameFile ExtensionNPM Package

You can override a .mustache file’s template engine. Read more at Changing a Template’s Rendering Engine.

Mustache Options #

Optional: Set your own Library instance New in v0.3.0 #

As an escape mechanism for advanced usage, pass in your own instance of the Mustache library using the Configuration API.

module.exports = function(eleventyConfig) {
let mustache = require("mustache");
eleventyConfig.setLibrary("mustache", mustache);

Supported Features #

✅ Partials{{> user}} looks for _includes/user.mustache. Does not process front matter in the include file.
🚫 Partials (Relative Path)Not yet supported: {{> ./user}} looks for user.mustache in the template’s current directory.

Other pages in Template Languages: