I'm wondering if there is a plan in place or timeline to integrate Prismic with Gatsby Cloud's incremental build feature? I watched Gatsby's demo video and would love to see Prismic as an option with this.
Hi fitzgers,
You can integrate prismic with gatsby-clouds incremental builds right now
Incremental builds will work better with gatsby-source-prismic
rather than our officially supported / documented plugin gatsby-source-prismic-graphql
.
The problem with this is that self-hosted previews with gatsby-source-prismic
require additional programming rather than with gatsby-source-prismic-graphql
, but if your using gatsby-cloud for previews this shouldn’t be an issue.
Best,
Marc
I’m interested what you mean when you say, “Incremental builds will work better with gatsby-source-prismic
…”
What are the disadvantages of continuing to use the gatsby-source-prismic-graphql
plugin with incremental builds?
Also, if we swap to using gatsby-source-prismic
, is it possible to trigger a Gatsby Cloud Preview build with the preview button in Prismic?
Thanks so much.
Rob
Hi Rob,
gatsby-source-graphql
plugins preform schema stitching (using an external graphql endpoint) to create the schema gatsby uses. If this schema changes a little then all the queries using that endpoint need to be rerun. Our understanding is that this is not the case with with other methods of generating the schema.
For gatsby previews you will need to set up a webhook to trigger the preview builds
Best,
Marc
Do you happen to have a full example repo that demonstrates how to set this all up?
Hi Teamgi,
It’s on my todo list
Thanks Marc, will you post it here when it’s done?
You can integrate prismic with gatsby-clouds incremental builds right now
This doesn't appear to be the case for me. The changes made on Prismic aren't being picked up in the incremental build on Gatsby Cloud. I'm using gatsby-source-prismic. I'd love to get this working if you can provide any hints.
Edit: OK, it seems to be partially working. Edits to content are being picked up. When content is added or removed, any listings don't seem to be updated. Will do some more testing and report back...
An update to my previous comment...
I created a test site and confirmed the following:
- Edits to content are working with an incremental build (pages and listings)
- New content is not picked up at all (no page generated, not added to listings) - manual rebuild required
- Removed content is also not picked up (page still exists, not removed from listings) - manual rebuild required
Any thoughts? I have also reached out to Gatsby Cloud support. Thanks!
Hi @ldevitt
Incremental builds for gatsby-source-prismic
is on the way.
There's a few things that need to be done, on the plugin this PR has to be merged. https://github.com/angeloashmore/gatsby-source-prismic/pull/255
And on out end we need to release a few new features in the writing room, also on the way.
Thanks for testing things out, we'll try and keep you informed when the features are released
Best,
Marc
Thanks, Marc, I'll keep an eye on that PR. I don't suppose you can give us a hint on what those new writing room features will be?
Hi, that's the PR to gatsby-source-prismic merged
There is also some documentation available here https://user-guides.prismic.io/en/articles/4464959-getting-started-with-gatsby-cloud-prismic
This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.