-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
GatsbyJs Hot Rebuild - CMS with Gatsby #615
Comments
Gatsby is a static site generator so it's not built with an admin interface that talks to some sort of live backend with an attached database. So for editing content, either you can edit the static files directly (e.g. Markdown) or you can integrate Gatsby with a hosted CMS like https://www.contentful.com/ or https://www.datocms.com/. You can set things up so that when you save a change to your content it rebuilds and deploys your site. DatoCMS just wrote a blog post showing this https://www.datocms.com/blog/one-click-websites/ There are other interesting things you could perhaps do with enough effort e.g. create a hosted service which pulls in your markdown files and lets you edit them in a browser editor and then on saving, creates a new Git commit with your changes and rebuilds/deploys the site. |
Great, thank you for giving me a direction. |
Hey, I am looking into this kind of functionality as well (for 1.0 version). Another approach I guess would be to fetch data from the browser only. If you have data with very frequent update it guess it would make sense to load that section in the browser only, after the first render, when the SPA is loaded. If you developed another approach to this, I am interested. |
I'm having a play with integrating Netlify CMS with a Gatsby powered site at the moment, however, I am running into an issue as the CMS content editor is accessed through a generic path: https://your-site/admin - whereas in my Gatsby site the router picks that up and displays the 404 page (rather than the Netlify CMS editor page) |
Actually - that was me just being a numpty (I hadn't set up the 'admin' folder manually). Seems to work just fine |
Spoke too soon - the router is getting in the way of serving the config.yaml file. I'll keep playing and raise an issue if there's no obvious work around (and stop just chatting to myself here) |
resolved - turns I'd named the config file .yaml rather than .yml |
@Rusta |
@Rusta I'm trying to set up netlify cms + gatsby as well. Would love to see how you did it. |
I am trying the same thing, I am wondering how to start local development |
It's been a while since I played with that but if things have not changed too much: |
@MarcCoet thanks. I put together a pretty good netlify cms and gatsby boilerplate in the few days, I will open source this week |
@AustinGreen There's also another effort here possibly. #623 (comment) |
@dustinmatlock you can follow my progress here: https://github.com/AustinGreen/gatsby-netlify-cms-boilerplate |
Oh nice, thanks! |
With the latest updates to netlify cms, it's now a lot easier to build a gatsby site w/ netlify cms. Here's my example project: https://github.com/AustinGreen/gatsby-netlify-cms-boilerplate. The developer experience + increased performance of using this stack compared to wordpress is really astounding. |
I think there are still a couple pain points right now with netlify-cms.
They are in very active development currently though and these fixes are on the roadmap. Personally I feel it's not something that's ready yet for wide use. |
Anyone have a good solution for images showing up in the live preview for netlify-cms? Currently working on a super hacky solution. |
Here is the hacky solution that I've been using to copy images into a static directory for the CMS preview: In gatsby-node.js:
then in the netlify CMS config.yml I'd love to know if anyone has a more elegant/optimized solution |
@huntercaron I'm struggling to make netlify-cms work. Can you help me with this? Thanks |
Thank you for your efforts Kyle. Gatsby looks very interesting and promising.
I have a question, the answer for which I didn't find or perhaps missed. Is it possible, after build to update pages contents? Say I create admin page and manage all the site's content, forcing other pages that were updated to rebuild? A GatsbyJs CMS of kind...
I thought of it as a wonderful opportunity to be made with Gatsby.
Would love to offer any help.
Thanks in advance.
The text was updated successfully, but these errors were encountered: