-
-
Notifications
You must be signed in to change notification settings - Fork 7.6k
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
Add headless page bundles #4311
Comments
As a quick and somewhat dirty fix, this makes sense. However long term i'm not sure it's ideal, or especially useful. Assuming in the longer-term that the On the other hand, if this is maintained after that implementation, it's possible it becomes a killer feature for someone in a situation I've not considered. Assuming it's not too much work, and doesn't end up breaking flow in weird ways in other places, I'd say go for it! |
That will not happen. Static is static, i.e. plain copy. This is not meant as "quick or dirty". You really need no explain a little what you mean by that? |
Only |
Damn, i'm clearly seeing things! I had assumed this was a quick fix, however if |
I'm talking headless bundles (i.e. the Imagine this in the home page template:
@RealOrangeOne Hugo is good at transforming content to websites. Content lives in |
This commit adds support for `headless bundles` for the `index` bundle type. So: ```toml headless = true ``` In front matter means that * It will have no `Permalink` and no rendered HTML in /public * It will not be part of `.Site.RegularPages` etc. But you can get it by: * `.Site.GetPage ...` The use cases are many: * Shared media galleries * Reusable page content "snippets" * ... Fixes gohugoio#4311
This commit adds support for `headless bundles` for the `index` bundle type. So: ```toml headless = true ``` In front matter means that * It will have no `Permalink` and no rendered HTML in /public * It will not be part of `.Site.RegularPages` etc. But you can get it by: * `.Site.GetPage ...` The use cases are many: * Shared media galleries * Reusable page content "snippets" * ... Fixes gohugoio#4311
This commit adds support for `headless bundles` for the `index` bundle type. So: ```toml headless = true ``` In front matter means that * It will have no `Permalink` and no rendered HTML in /public * It will not be part of `.Site.RegularPages` etc. But you can get it by: * `.Site.GetPage ...` The use cases are many: * Shared media galleries * Reusable page content "snippets" * ... Fixes gohugoio#4311
This commit adds support for `headless bundles` for the `index` bundle type. So: ```toml headless = true ``` In front matter means that * It will have no `Permalink` and no rendered HTML in /public * It will not be part of `.Site.RegularPages` etc. But you can get it by: * `.Site.GetPage ...` The use cases are many: * Shared media galleries * Reusable page content "snippets" * ... Fixes #4311
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
We have a fairly solid page bundle story now, with metadata support and powerful glob matching. There are probably some improvements to be had here as well (linking resources outside of the bundle, metadata outside of front matter), but that will have to wait.
There are, however, popping up questions about "how to reuse images?" and similar, and people are creating more or less elegant hacks. We have similar requests for reuse of content files (many obvious use cases here, see #3612).
We should give people a good solution for this sooner rather than later. This is a low hanging fruit: Big win for little effort.
I suggest that we establish support for
headless bundles
for theindex
bundle type.So:
In front matter means that
Permalink
and no rendered HTML in /public.Site.RegularPages
etc.But you can get it by:
.Site.GetPage ...
Thoughts?
The text was updated successfully, but these errors were encountered: