title: Is Jquery post during window beforeunload event a bad idea?
body: <p>I'm getting my web app to post a small (200 bytes) JSON file with a few user settings back to the server when the user closes the browser window or navigates away ( <code>$(window).on('beforeunload')</code> ). Post call is:</p>
  
  <pre><code>$.post('/backendscript', { mydata: jsonstr });
  </code></pre>
  
  <p>so no waiting for a callback. Just wondering if this is bad for some unforseen reason, e.g. could hold up browser from closing, or browser window could shut down before data sent, etc.?</p>
  
  <p>Thanks</p>