Comparing version 2.0.17 to 2.0.18
{ | ||
"name": "jwidget", | ||
"version": "2.0.17", | ||
"version": "2.0.18", | ||
"description": "Object-oriented FrontEnd MV framework", | ||
@@ -5,0 +5,0 @@ "homepage": "http://enepomnyaschih.github.io/jwidget", |
/// <reference types="jquery" /> | ||
import CancelToken from "./CancelToken"; | ||
export default function request(xhr?: JQueryXHR, cancelToken?: CancelToken): Promise<any>; | ||
/** | ||
* Promise wrapper over jQuery AJAX API functions with CancelToken support. Resolves the promise with request result on its | ||
* successful completion. Rejects the promise with XMLHttpRequest on request failure. If the operation gets | ||
* cancelled via the token, the promise never gets resolved or rejected. | ||
* @param xhr jQuery XML HTTP request wrapper object. | ||
* @param cancelToken Cancellation token to bind the operation to. | ||
* @returns Promise object representing the request. | ||
*/ | ||
export default function request(xhr: JQueryXHR, cancelToken?: CancelToken): Promise<any>; |
@@ -23,2 +23,10 @@ "use strict"; | ||
var CancelToken_1 = require("./CancelToken"); | ||
/** | ||
* Promise wrapper over jQuery AJAX API functions with CancelToken support. Resolves the promise with request result on its | ||
* successful completion. Rejects the promise with XMLHttpRequest on request failure. If the operation gets | ||
* cancelled via the token, the promise never gets resolved or rejected. | ||
* @param xhr jQuery XML HTTP request wrapper object. | ||
* @param cancelToken Cancellation token to bind the operation to. | ||
* @returns Promise object representing the request. | ||
*/ | ||
function request(xhr, cancelToken) { | ||
@@ -25,0 +33,0 @@ var aborted = false; |
@@ -23,3 +23,11 @@ /* | ||
export default function request(xhr?: JQueryXHR, cancelToken?: CancelToken) { | ||
/** | ||
* Promise wrapper over jQuery AJAX API functions with CancelToken support. Resolves the promise with request result on its | ||
* successful completion. Rejects the promise with XMLHttpRequest on request failure. If the operation gets | ||
* cancelled via the token, the promise never gets resolved or rejected. | ||
* @param xhr jQuery XML HTTP request wrapper object. | ||
* @param cancelToken Cancellation token to bind the operation to. | ||
* @returns Promise object representing the request. | ||
*/ | ||
export default function request(xhr: JQueryXHR, cancelToken?: CancelToken) { | ||
let aborted = false; | ||
@@ -26,0 +34,0 @@ return runAsync<any>( |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1893973
41941