mirror of
https://github.com/tenrok/axios.git
synced 2026-05-15 11:59:42 +03:00
Releasing 0.17.0
This commit is contained in:
+1
-1
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "axios",
|
||||
"main": "./dist/axios.js",
|
||||
"version": "0.16.2",
|
||||
"version": "0.17.0",
|
||||
"homepage": "https://github.com/axios/axios",
|
||||
"authors": [
|
||||
"Matt Zabriskie"
|
||||
|
||||
Vendored
+80
-63
@@ -1,4 +1,4 @@
|
||||
/* axios v0.16.2 | (c) 2017 by Matt Zabriskie */
|
||||
/* axios v0.17.0 | (c) 2017 by Matt Zabriskie */
|
||||
(function webpackUniversalModuleDefinition(root, factory) {
|
||||
if(typeof exports === 'object' && typeof module === 'object')
|
||||
module.exports = factory();
|
||||
@@ -53,13 +53,13 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
/************************************************************************/
|
||||
/******/ ([
|
||||
/* 0 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
module.exports = __webpack_require__(1);
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 1 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -115,9 +115,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
module.exports.default = axios;
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 2 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -424,9 +424,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 3 */
|
||||
/***/ function(module, exports) {
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -441,9 +441,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 4 */
|
||||
/***/ function(module, exports) {
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
/*!
|
||||
* Determine if an object is a Buffer
|
||||
@@ -468,9 +468,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
}
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 5 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -478,8 +478,6 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
var utils = __webpack_require__(2);
|
||||
var InterceptorManager = __webpack_require__(17);
|
||||
var dispatchRequest = __webpack_require__(18);
|
||||
var isAbsoluteURL = __webpack_require__(21);
|
||||
var combineURLs = __webpack_require__(22);
|
||||
|
||||
/**
|
||||
* Create a new instance of Axios
|
||||
@@ -511,11 +509,6 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
config = utils.merge(defaults, this.defaults, { method: 'get' }, config);
|
||||
config.method = config.method.toLowerCase();
|
||||
|
||||
// Support baseURL config
|
||||
if (config.baseURL && !isAbsoluteURL(config.url)) {
|
||||
config.url = combineURLs(config.baseURL, config.url);
|
||||
}
|
||||
|
||||
// Hook up interceptors middleware
|
||||
var chain = [dispatchRequest, undefined];
|
||||
var promise = Promise.resolve(config);
|
||||
@@ -560,9 +553,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
module.exports = Axios;
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 6 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -658,9 +651,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
module.exports = defaults;
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 7 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -676,9 +669,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 8 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -706,7 +699,8 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
// For IE 8/9 CORS support
|
||||
// Only supports POST and GET calls and doesn't returns the response headers.
|
||||
// DON'T do this for testing b/c XMLHttpRequest is mocked, not XDomainRequest.
|
||||
if (("production") !== 'test' &&
|
||||
if (!window.XMLHttpRequest &&
|
||||
("production") !== 'test' &&
|
||||
typeof window !== 'undefined' &&
|
||||
window.XDomainRequest && !('withCredentials' in request) &&
|
||||
!isURLSameOrigin(config.url)) {
|
||||
@@ -748,7 +742,7 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response;
|
||||
var response = {
|
||||
data: responseData,
|
||||
// IE sends 1223 instead of 204 (https://github.com/mzabriskie/axios/issues/201)
|
||||
// IE sends 1223 instead of 204 (https://github.com/axios/axios/issues/201)
|
||||
status: request.status === 1223 ? 204 : request.status,
|
||||
statusText: request.status === 1223 ? 'No Content' : request.statusText,
|
||||
headers: responseHeaders,
|
||||
@@ -862,9 +856,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 9 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -894,9 +888,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 10 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -918,9 +912,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 11 */
|
||||
/***/ function(module, exports) {
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -945,9 +939,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 12 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1019,14 +1013,23 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 13 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
var utils = __webpack_require__(2);
|
||||
|
||||
// Headers whose duplicates are ignored by node
|
||||
// c.f. https://nodejs.org/api/http.html#http_message_headers
|
||||
var ignoreDuplicateOf = [
|
||||
'age', 'authorization', 'content-length', 'content-type', 'etag',
|
||||
'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since',
|
||||
'last-modified', 'location', 'max-forwards', 'proxy-authorization',
|
||||
'referer', 'retry-after', 'user-agent'
|
||||
];
|
||||
|
||||
/**
|
||||
* Parse headers into an object
|
||||
*
|
||||
@@ -1054,7 +1057,14 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
val = utils.trim(line.substr(i + 1));
|
||||
|
||||
if (key) {
|
||||
parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;
|
||||
if (parsed[key] && ignoreDuplicateOf.indexOf(key) >= 0) {
|
||||
return;
|
||||
}
|
||||
if (key === 'set-cookie') {
|
||||
parsed[key] = (parsed[key] ? parsed[key] : []).concat([val]);
|
||||
} else {
|
||||
parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@@ -1062,9 +1072,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 14 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1136,9 +1146,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
);
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 15 */
|
||||
/***/ function(module, exports) {
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1178,9 +1188,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
module.exports = btoa;
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 16 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1237,9 +1247,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
);
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 17 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1295,9 +1305,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
module.exports = InterceptorManager;
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 18 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1305,6 +1315,8 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
var transformData = __webpack_require__(19);
|
||||
var isCancel = __webpack_require__(20);
|
||||
var defaults = __webpack_require__(6);
|
||||
var isAbsoluteURL = __webpack_require__(21);
|
||||
var combineURLs = __webpack_require__(22);
|
||||
|
||||
/**
|
||||
* Throws a `Cancel` if cancellation has been requested.
|
||||
@@ -1324,6 +1336,11 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
module.exports = function dispatchRequest(config) {
|
||||
throwIfCancellationRequested(config);
|
||||
|
||||
// Support baseURL config
|
||||
if (config.baseURL && !isAbsoluteURL(config.url)) {
|
||||
config.url = combineURLs(config.baseURL, config.url);
|
||||
}
|
||||
|
||||
// Ensure headers exist
|
||||
config.headers = config.headers || {};
|
||||
|
||||
@@ -1380,9 +1397,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 19 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1406,9 +1423,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 20 */
|
||||
/***/ function(module, exports) {
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1417,9 +1434,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 21 */
|
||||
/***/ function(module, exports) {
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1437,9 +1454,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 22 */
|
||||
/***/ function(module, exports) {
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1457,9 +1474,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 23 */
|
||||
/***/ function(module, exports) {
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1482,9 +1499,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
module.exports = Cancel;
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 24 */
|
||||
/***/ function(module, exports, __webpack_require__) {
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1545,9 +1562,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
module.exports = CancelToken;
|
||||
|
||||
|
||||
/***/ },
|
||||
/***/ }),
|
||||
/* 25 */
|
||||
/***/ function(module, exports) {
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
'use strict';
|
||||
|
||||
@@ -1578,7 +1595,7 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||
};
|
||||
|
||||
|
||||
/***/ }
|
||||
/***/ })
|
||||
/******/ ])
|
||||
});
|
||||
;
|
||||
|
||||
Vendored
+1
-1
File diff suppressed because one or more lines are too long
Vendored
+3
-3
File diff suppressed because one or more lines are too long
Vendored
+1
-1
File diff suppressed because one or more lines are too long
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "axios",
|
||||
"version": "0.16.2",
|
||||
"version": "0.17.0",
|
||||
"description": "Promise based HTTP client for the browser and node.js",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
|
||||
Reference in New Issue
Block a user