craftcms / gatsby-helper

Craft CMS helper plugin for Gatsby.
https://plugins.craftcms.com/gatsby-helper
MIT License
15 stars 6 forks source link

Making one edit causes 4 calls to Gatsby Cloud #14

Closed richardfrankza closed 3 years ago

richardfrankza commented 3 years ago

It seems there is not sufficient debounce on the posts to the preview server. I can make one small edit on a page and it posts 4 separate events. Does it run a preview HTTP POST on every keystroke?


image

andris-sevcenko commented 3 years ago

Good point, I'll see that it happens!

andris-sevcenko commented 3 years ago

Is this by chance when saving an entry with some matrix fields?

richardfrankza commented 3 years ago

Nearly all my pages have matrix fields, so yes!

On Mon, 5 Jul 2021 at 13:18, Andris Sevcenko @.***> wrote:

Is this by chance when saving an entry with some matrix fields?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/craftcms/gatsby-helper/issues/14#issuecomment-874033068, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEFWJBFNLQEZPELWG5VT5PLTWGIJXANCNFSM47E7QV6A .

andris-sevcenko commented 3 years ago

The plugin should only be sending one build request per entry save.

Which helper version are you using? Do you have any other plugins installed? We're talking about the build URL, not the preview URL, correct?

richardfrankza commented 3 years ago

No I was talking about the preview server and url - check original message, thanks!

andris-sevcenko commented 3 years ago

Interesting. Do you have the build URL also set up?

richardfrankza commented 3 years ago

Yes I have both set up.

andris-sevcenko commented 3 years ago

Okay, then I can account for three of those events. I'll look into improving this.

andris-sevcenko commented 3 years ago

@richardfrankza we discussed this internally and I'll try to cut a release with improvements tomorrow!

richardfrankza commented 3 years ago

awesome news, we are struggling a bit with authoring experience, especially existing CraftCMS users we are converting to headless. They are used to instant results, so anything to improve preview and build experience is very key for us right now. To be honest we have clients saying they want to go back to their old Craft 2!

On Mon, 5 Jul 2021 at 16:25, Andris Sevcenko @.***> wrote:

@richardfrankza https://github.com/richardfrankza we discussed this internally and I'll try to cut a release with improvements tomorrow!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/craftcms/gatsby-helper/issues/14#issuecomment-874154301, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEFWJBFAXMJVL43MHJPQBALTWG6E5ANCNFSM47E7QV6A .

--

Richard Frank Head of digital

Mobile 27(0)832915952

Tel 27(0)870958182

Email @.***

Website www.flowsa.com

andris-sevcenko commented 3 years ago

Just cut the 1.0.4 release that should improve this for you.

Removed the unneeded things:

Also, added a page build trigger if a non-draft/revision element is deleted.