codex
codex copied to clipboard
allow default layouts
The fact that codex lets me have nested directories is the killer feature I need for the TC39 wiki, which many other static site generators (like Jekyll) don't seem to support. But it would be great if nested directories could default to their parents' layouts, instead of having to create new layout files for every child.
Dave
You can currently use the template
header tag in the markdown file to overwrite which template to use so you don't have tons of template files. The template name is the filename of the template without the .jade
extension.
I will see about having the pages plugin intelligently traverse up its parent's tree to find an available template. Until then, this will allow to clean up your template folder.
I don't think that would be much of an improvement since there are generally many more .md files than templates. This isn't a deal-breaker or anything, but I think defaulting up the parent hierarchy would be a good convenience to support.
Thanks, Dave