Skip to content

Feature removal: ambiguous layout file search #1924

@zachleat

Description

@zachleat

If you omit the file extension (for example layout: mylayout), Eleventy will cycle through all of the supported template formats (mylayout.*) to look for a matching layout file.

https://www.11ty.dev/docs/layouts/#omitting-the-layouts-file-extension

I’d like to phase out the above feature and make it not enabled by default, with the option to re-enable via config option.

This feature requires potentially 10 or 11 file system checks (one per template extension) and the ordering is ambiguous. If you have a base.liquid and base.njk—which does it select? I think for this specific case it’s better to be explicit, especially as we improve incremental builds.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions