Is there a way to bar the user from clicking the "X" button on a browser to exit the app forcefully if certain boolean variable in the app is not TRUE?
I feel this has to do with connecting Shiny with Javascript somehow. Saw an example that display a popup prompt when the user closes the browswer here. But in this example, the user can still forcefully leave the browser.
But I don't know anything about Javascript to go on from there.
Any advice would be much appreciated.
Thanks,