Using Data
Data can be used on a template from multiple different sources.
- Configure your Templates: Set data to configure how your template behaves in Eleventy.
- Eleventy Supplied Data: Use data that Eleventy provides to you.
- Set your own data anywhere in the Data Cascade to render in your templates.
Sources of Data
When the data is merged in the Eleventy Data Cascade, the order of priority for sources of data is (from highest priority to lowest):
- Computed Data
- Front Matter Data in a Template
- Template Data Files
- Directory Data Files (and ascending Parent Directories)
- Front Matter Data in Layouts (this moved in 1.0)
- Configuration API Global Data
- Global Data Files
From the Community
Other pages in Eleventy Projects
- Get Started
- Command Line Usage
- Add a Configuration File
- Copy Files to Output
- Add CSS, JS, Fonts
- Importing Content
- Configure Templates with Data
- Using Data in Templates
- Template Languages
- Template Features
- Environment Variables
- Internationalization (i18n)
- Watch Files and Dev Servers
- Common Pitfalls
- Advanced
