Skip to content

Instantly share code, notes, and snippets.

@dv
Last active December 25, 2015 14:19
Show Gist options
  • Save dv/6990136 to your computer and use it in GitHub Desktop.
Save dv/6990136 to your computer and use it in GitHub Desktop.
Serialized AJAX requests (JQuery)
$.serialAjax = (options...) ->
window.serialAjaxPromise ||= $.Deferred().resolve().promise()
window.serialAjaxPromise =
window.serialAjaxPromise.then -> $.ajax(options...)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment