View on GitHub


jQuery plugin to animate buttons when an asynchronous process is waiting to complete (ajax, etc.)

Download this project as a .zip file Download this project as a tar.gz file

jQuery Async Demo

Project page »

Asynchronous button

Instead of using the .click() jQuery function, use the .async() to make your button visibly wait.

The action can either succeed of fail, triggering a different animation on the button.

Test asynchronous user action

Embed the params in the HTML attributes

If your javascript is bundled and minified, you cannot easily pass a page parameter like a user id to the javascript function.

jQuery async does that for you by reading the async-params attribute of your button in a JSON format and deliver it in your code

Test embedded params

Different triggers

You can bind .async() on a different trigger than the usual "click" event

In this example the async is binded to the "change" event so once you have typed in the postal code and you leave the input, the function is triggered: