You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sanity is a great tool and the only thing that is bugging me ever since I started using it is that it triggers a webhook everytime I hit the Save button. This may lead to useless builds if you do plenty of updates.
Having a Publish All button or a Deploy button that would save all the documents and trigger one single webhook could be one option but I understand this would come with a lot of problems for the UI etc.
I recently thought of having an option to defer the webhook itself. If there was an optional feature to say "Wait x seconds before triggering this webhook" where every other create/edit/delete action would restart the timer further delaying the webhook this could reduce the number of builds which is desirable economically as well as ecologically.
Sanity is a great tool and the only thing that is bugging me ever since I started using it is that it triggers a webhook everytime I hit the Save button. This may lead to useless builds if you do plenty of updates.
Having a Publish All button or a Deploy button that would save all the documents and trigger one single webhook could be one option but I understand this would come with a lot of problems for the UI etc.
I recently thought of having an option to defer the webhook itself. If there was an optional feature to say "Wait x seconds before triggering this webhook" where every other create/edit/delete action would restart the timer further delaying the webhook this could reduce the number of builds which is desirable economically as well as ecologically.
What do you think?
+1.
I am facing a same issue. I wanna build static pages using cdn api, but want to revalidate using non-cdn. So, immediate changes are not affected. To make this work, I had to create one api as a via. So, the webhook hits that api, that api does the delay (throttle, debounce) and forward to the nextjs api.
But I really would like the defer option by default.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi all,
Sanity is a great tool and the only thing that is bugging me ever since I started using it is that it triggers a webhook everytime I hit the Save button. This may lead to useless builds if you do plenty of updates.
Having a Publish All button or a Deploy button that would save all the documents and trigger one single webhook could be one option but I understand this would come with a lot of problems for the UI etc.
I recently thought of having an option to defer the webhook itself. If there was an optional feature to say "Wait x seconds before triggering this webhook" where every other create/edit/delete action would restart the timer further delaying the webhook this could reduce the number of builds which is desirable economically as well as ecologically.
What do you think?
Beta Was this translation helpful? Give feedback.
All reactions