Closed kcoderhtml closed 9 months ago
Yeah, that can be a problem in certain cases. I have a few ideas on how to fix it, with different pros and cons.
I was thinking of a system where Webhooks run in 30s or 1 min after the actual event, with the user getting a Notification in the dashboard with options to "Run now" or "Cancel". That said, with Webhooks being triggered on the backend (also in response to changes made through API), it's a bit tricky to implement.
Other solution would be some sort of batching, where the wait period is longer, but all changes made in certain time window come as one. That said, in case you want the Webhooks to run immediately (or relatively fast), batching will stand in the way.
It's possible to add a different button/trigger that could be connected to a different Webhook and run manually, e.g. on click. The drawbacks are - you lose a degree of automation, and have to use this trigger instead of just working with the content.
I was thinking of a combination of the batching and the delay methods. An event would trigger the countdown of 1-1/2 m and the counter would reset if an event happened during that time period. You could also display this as a bar across the top of the screen that will go down with the timer, as well as buttons for cancel and run now.
As for the button to deploy, it could be an optional feature.
Will think on this and likely implement some kind of combination of all mentioned solutions. That said, it's not on the immediate roadmap for now.
Awesome! Thanks.
I thought deeply about implementing it in v0.4. Ultimately I decided not to, due to the following reasons:
Your issue should instead be handled by a system like Changesets (#57) - a WIP concept for applying multiple changes to a workspace at once;
That seems like a perfect solution! That basically accomplishes what I wanted with the webhooks button.
I personally use Netlify to host my sites, but if I do some shuffling of my pages, then 3-4 or more builds can all be triggered. An optional addition to the webhooks could be to have a period that it waits for any more changes before triggering.