mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-11 11:50:54 +08:00
Added generic typing to jQuery.when
This commit is contained in:
@@ -2294,4 +2294,8 @@ function test_EventIsNewable() {
|
||||
|
||||
function test_EventIsCallable() {
|
||||
var ev = jQuery.Event('click');
|
||||
}
|
||||
}
|
||||
|
||||
var f1: JQueryPromise<string> = $.when("fetch");
|
||||
var f2: JQueryPromise<string[]> = f1.then(s => [s, s]);
|
||||
var f3: JQueryPromise<number> = f2.then(v => 3);
|
||||
|
||||
Reference in New Issue
Block a user