aboutsummaryrefslogtreecommitdiffstats
path: root/src/deprecated/ajax-event-alias.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/deprecated/ajax-event-alias.js')
-rw-r--r--src/deprecated/ajax-event-alias.js17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/deprecated/ajax-event-alias.js b/src/deprecated/ajax-event-alias.js
new file mode 100644
index 000000000..e4fe11525
--- /dev/null
+++ b/src/deprecated/ajax-event-alias.js
@@ -0,0 +1,17 @@
+import jQuery from "../core.js";
+
+import "../ajax.js";
+import "../event.js";
+
+jQuery.each( [
+ "ajaxStart",
+ "ajaxStop",
+ "ajaxComplete",
+ "ajaxError",
+ "ajaxSuccess",
+ "ajaxSend"
+], function( _i, type ) {
+ jQuery.fn[ type ] = function( fn ) {
+ return this.on( type, fn );
+ };
+} );