UNPKG

@fmal/http-service

Version:

A HTTP service - orignally @cerebral/http

36 lines (30 loc) 1.05 kB
import _inheritsLoose from "@babel/runtime/helpers/esm/inheritsLoose"; import _wrapNativeSuper from "@babel/runtime/helpers/esm/wrapNativeSuper"; export var HttpServiceErrorTypes; (function (HttpServiceErrorTypes) { HttpServiceErrorTypes["Http"] = "http"; HttpServiceErrorTypes["Abort"] = "abort"; HttpServiceErrorTypes["Timeout"] = "timeout"; })(HttpServiceErrorTypes || (HttpServiceErrorTypes = {})); export var HttpServiceError = /*#__PURE__*/ function (_Error) { _inheritsLoose(HttpServiceError, _Error); function HttpServiceError() { var _this; for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) { args[_key] = arguments[_key]; } _this = _Error.call.apply(_Error, [this].concat(args)) || this; _this.type = void 0; _this.response = void 0; return _this; } return HttpServiceError; }(_wrapNativeSuper(Error)); export var FileUpload = function FileUpload() { this.xhr = void 0; this.isAborted = void 0; this.send = void 0; this.abort = void 0; };