- Stable
3.0.0
Toggle Menu
Eleventy
5.81s
Remix
40.14s
Configure your Templates
There are a few special data keys you can assign in your data to control how templates behave. These can live anywhere in the Data Cascade.
permalink
: Change the output target of the current template. Normally, you cannot use template syntax to reference other variables in your data, butpermalink
is an exception. Read more about Permalinks.layout
: Wrap current template with a layout template found in the_includes
folder. Read more about Layouts.pagination
: Enable to iterate over data. Output multiple HTML files from a single template. Read more about Pagination.tags
: A single string or array that identifies that a piece of content is part of a collection. Collections can be reused in any other template. Read more about Collections.date
: Override the default date (file creation) to customize how the file is sorted in a collection. Read more at Content Dates.templateEngineOverride
: Override the template engine on a per-file basis. Read more about Changing a Template’s Rendering Engine. This option only works in Front Matter ⚠️ (for now), read Issue #445.eleventyExcludeFromCollections
: Set totrue
to exclude this content from any and all Collections (those tagged in data or setup using the Configuration API).eleventyComputed
: Programmatically set data values based on other values in your data cascade. Read more about Computed Data.eleventyDataSchema
: Used to validate data in the data cascade.eleventyNavigation
: Used by the Navigation plugin.
Advanced
eleventyImport
eleventyImport.collections
: Added in v2.0.0 An Array of collection names used to inform template dependencies for incremental builds and to render templates in the correct order. Read more on the collections documentation.
dynamicPermalink
: Option to disable template syntax for thepermalink
key. Read more about disabling dynamic permalinks.permalinkBypassOutputDir
: Write a file to somewhere other than the output directory. Read more about bypassing the output directory