Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do you specify a default layout for all pages in eleventy?

Tags:

It seems like you should be able to specify a fallback layout for all pages in an 11ty site using global data files and the data cascade, but I can't figure out how.

I've tried the following JSON in several locations:

{
  "layout": "layouts/page.njk"
}

I've put this JSON in:

  • _data/default.json
  • _data/site.json
  • _data/site.11tydata.json
  • _data/11tydata.json

So far no luck.