I have nothing to do today, I suddenly think of how to click on the closing button in the upper right corner, check the information, I found this function is particularly useful, window. Onbeforeunload (); we can be unkwear When you click this, you can give a tip or do something else.