-
-
Notifications
You must be signed in to change notification settings - Fork 7.5k
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
Create Pages from GraphQL queries #4910
Comments
I'm not necessarily opposed to a feature like this, but to me it seems like it would be very difficult to manage the trade-off between power and simplicity. Allowing users to specify a GraphQL query via configuration might be simple enough, but then where do the fetched pages end up in the directory structure? How often does the fetching happen? How would authentication for GraphCMS/Contentful/whatever be handled? Right now the "Hugo Way" is to make gathering inputs a process that happens outside of Hugo, with the exception of things like I'm not saying that a GraphQL implementation is impossible per se. I'm just skeptical that there's enough similarity across GraphQL content backends to make a feature like this generally useful. It seems more likely to me that users would end up needing to roll their own content gathering solutions anyway. |
In a different mood, what would be super cool would be some kind of API standard for GraphQL content gathering, a standard to which existing GraphQL content providers could be pressured to conform. This would provide a solid "contractual" basis for tools like Hugo, Gatsby, Jekyll, Middleman, and the like to provide their own GraphQL implementations. The standard could cover auth*, directory organization, file metadata, etc. Not gonna hold my breath, though! |
Gatsby has Source Plugins https://www.gatsbyjs.org/docs/create-source-plugin/ that help integrate with a Headless CMS. See https://hackernoon.com/building-a-static-blog-using-gatsby-and-strapi-8b5acfc82ad8 |
Hopefully this would fall under #5074 |
Duplicates #5074 (kind of) |
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. |
This would Hugo enable to adapt to an API based Headless CMS.
Context:
"Pages from “other data sources”
Currently, in addition to Hugo’s list pages, every URL must be backed by a content file (Markdown, HTML etc.). This covers most use cases, but we need a flexible way to generate pages from other data sources. Think product catalogues and similar."
See http://gohugo.io/news/lets-celebrate-hugos-5th-birthday/
The text was updated successfully, but these errors were encountered: