Skip to content

Instantly share code, notes, and snippets.

@zlatkov
Last active October 11, 2017 14:33
Show Gist options
  • Save zlatkov/1b834ae5eb037f46347d71d4c497d43c to your computer and use it in GitHub Desktop.
Save zlatkov/1b834ae5eb037f46347d71d4c497d43c to your computer and use it in GitHub Desktop.
// This is assuming that you're using jQuery
jQuery.ajax({
url: 'https://api.example.com/endpoint',
success: function(response) {
// This is your callback.
},
async: false // And this is a terrible idea
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment