Comparing version 0.0.7 to 0.0.8
import { Http, RequestOptionsArgs, Response, URLSearchParams } from "@angular/http"; | ||
import { Subject } from "rxjs/Subject"; | ||
import { BehaviorSubject } from "rxjs/BehaviorSubject"; | ||
export declare class HttpService { | ||
@@ -8,3 +8,4 @@ baseUrl: string; | ||
protected _currentRequestCount: number; | ||
requestCount: Subject<number>; | ||
protected _requestCount: BehaviorSubject<number>; | ||
readonly requestCount: BehaviorSubject<number>; | ||
constructor(baseUrl: string, http: Http); | ||
@@ -11,0 +12,0 @@ get<T>(url: string, query?: any): Promise<T>; |
@@ -40,3 +40,3 @@ "use strict"; | ||
var http_error_1 = require("../error/http-error"); | ||
var Subject_1 = require("rxjs/Subject"); | ||
var BehaviorSubject_1 = require("rxjs/BehaviorSubject"); | ||
var HttpService = (function () { | ||
@@ -47,3 +47,3 @@ function HttpService(baseUrl, http) { | ||
this._currentRequestCount = 0; | ||
this.requestCount = new Subject_1.Subject(); | ||
this._requestCount = new BehaviorSubject_1.BehaviorSubject(this.currentRequestCount); | ||
} | ||
@@ -61,2 +61,9 @@ Object.defineProperty(HttpService.prototype, "currentRequestCount", { | ||
}); | ||
Object.defineProperty(HttpService.prototype, "requestCount", { | ||
get: function () { | ||
return this._requestCount; | ||
}, | ||
enumerable: true, | ||
configurable: true | ||
}); | ||
HttpService.prototype.get = function (url, query) { | ||
@@ -63,0 +70,0 @@ return __awaiter(this, void 0, void 0, function () { |
{ | ||
"name": "innong", | ||
"version": "0.0.7", | ||
"version": "0.0.8", | ||
"description": "Angular ecom rnd lib", | ||
@@ -5,0 +5,0 @@ "main": "build/index.js", |
61888
626