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

Disable default layouts for documents with a layout: none declaration #5933

Merged
merged 2 commits into from
May 15, 2017

Conversation

ashmaroli
Copy link
Member

Inspired by discussion in #5929

While layout: null will still continue to be overridden by the defaults, with this pull in place, the user will be able to process and output a Jekyll::Document object without being placed into a layout by
simply declaring layout: none in the Front Matter

/cc @jekyll/ecosystem

Let me know if this results in any unintended behavior.. I'll update as required.

@parkr
Copy link
Member

parkr commented Mar 7, 2017

This should be layout: null. I don't know if I like us fiddling with the way YAML works.

@ashmaroli
Copy link
Member Author

This should be layout: null. I don't know if I like us fiddling with the way YAML works.

IMO, the proposed approach is better because it introduces a new route and only affects Jekyll::Document objects..
Modifying layout: null will require modification of #deep_merge_hashes which is used by various other objects

@parkr
Copy link
Member

parkr commented Mar 31, 2017

Ugh, I don't love this. If I had a _layouts/none.html file and layout: none today, then after this PR, I wouldn't have a layout on my page anymore. That seems like a breaking change.

A brief search shows that it's probably safe....

@benbalter, I think this could be an acceptable breaking change. Thoughts?

@parkr parkr requested a review from benbalter March 31, 2017 05:39
@mattr-
Copy link
Member

mattr- commented May 12, 2017

IMHO, this is definitely a breaking change. I'm also not sure what the use case for this would be when we have the standard YAML version already in layout: null.

@pathawks
Copy link
Member

we have the standard YAML version already in layout: null.

That's the problem: we don't. When we merge the defaults into a document’s front matter, we will override layout: null the same way we would if no layout were specified at all.

@parkr
Copy link
Member

parkr commented May 15, 2017

@jekyllbot: merge +minor

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants