Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rethink layout loading order #42

Open
ericselin opened this issue Feb 21, 2022 · 0 comments
Open

Rethink layout loading order #42

ericselin opened this issue Feb 21, 2022 · 0 comments
Labels
api Core public API enhancement New feature or request

Comments

@ericselin
Copy link
Owner

ericselin commented Feb 21, 2022

Layout loading should be expanded to provide sensible defaults:

  • Based on type set in frontmatter
    type might very reasonably be used to represent the page ... type. So a type of order should have order.tsx in the list of tried layouts.
  • Based on subfolder
    The following content file orders/123.md would benefit from inserting a folder-based layout for the list of layouts, i.e. this should by default load the orders.tsx layout.
@ericselin ericselin added this to the v2.7 - Theme helpers milestone Feb 21, 2022
@ericselin ericselin changed the title Make layout loading based on folder Rethink layout loading order Feb 23, 2022
@ericselin ericselin added api Core public API enhancement New feature or request labels Feb 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Core public API enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant