I’m trying to make a simple delete confirmation using the App Bridge modal in a remix-based app (using the shopify template). The examples in the modal docs suggest this should be easy – but the examples just console.log
on the button presses.
To actually make the delete happen, I need to submit a DELETE into one of my remix routes. I am able to do this, e.g. with fetch
or even useSubmit
from remix, but I’d like to trigger a navigation like a usual remix form so that the underlying app page will revalidate, or so that I can go to a different page.
Does anyone have an example of how to actually carry out mutations via the modal confirmation? This is supposed to be a “simple” case according to the Shopify modal examples, but it seems to not be. How does the app know I’m “confirming” the deletion?