Scenario:
I’m developing a Dash app that generates a new directory with unique ID, that allows users to upload and submit files to the directory. Sometimes, users may not click the submit button after uploading files to the directory. They will navigate to another page or close the browser.
Questions:
- How do we alert the user that “Do you still want to submit the files?” before they navigate to another page or close the browser?
- If the user navigates away from the upload page without submitting, how do we create callbacks to detect that and remove the folder created + files uploaded?