Build: Add `exports` to package.json, export slim & esm builds
[jquery.git] / test / promises_aplus_adapters / deferred.cjs
blob5e3ffe2d854839545b0a9b53f1e661b408433d5a
1 "use strict";
3 const { JSDOM } = require( "jsdom" );
5 const { window } = new JSDOM( "" );
7 const jQuery = require( "../../" )( window );
9 module.exports.deferred = () => {
10         const deferred = jQuery.Deferred();
12         return {
13                 promise: deferred.promise(),
14                 resolve: deferred.resolve.bind( deferred ),
15                 reject: deferred.reject.bind( deferred )
16         };