@luminix/support 0.4.2 → 0.4.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/support.js +21 -14
- package/package.json +1 -1
- package/types/Http/Client.d.ts +2 -2
package/dist/support.js
CHANGED
|
@@ -4262,18 +4262,16 @@ class Sm extends yr {
|
|
|
4262
4262
|
this.emit("flushing"), this.singletons = {}, this.loaders = {}, this._configuration = {}, this.providers = [], this.emit("flushed"), this.flushEvents();
|
|
4263
4263
|
}
|
|
4264
4264
|
dump(r = !1) {
|
|
4265
|
-
const n =
|
|
4266
|
-
|
|
4267
|
-
|
|
4268
|
-
|
|
4269
|
-
|
|
4270
|
-
|
|
4271
|
-
|
|
4272
|
-
|
|
4273
|
-
|
|
4274
|
-
|
|
4275
|
-
r === !1 && n.info(s), n.info(r, s);
|
|
4276
|
-
}
|
|
4265
|
+
const n = {
|
|
4266
|
+
configuration: this.configuration,
|
|
4267
|
+
services: this.services,
|
|
4268
|
+
providers: this.providers,
|
|
4269
|
+
singletons: this.singletons
|
|
4270
|
+
};
|
|
4271
|
+
if (r === !0)
|
|
4272
|
+
return n;
|
|
4273
|
+
const s = this.make("log");
|
|
4274
|
+
r === !1 && s.info(n), s.info(r, n);
|
|
4277
4275
|
}
|
|
4278
4276
|
}
|
|
4279
4277
|
function Re(e) {
|
|
@@ -4517,10 +4515,19 @@ class xm {
|
|
|
4517
4515
|
return this.options = t, this;
|
|
4518
4516
|
}
|
|
4519
4517
|
withQueryParameters(t) {
|
|
4520
|
-
|
|
4518
|
+
const r = typeof t == "string" ? O.fromQuery(new URLSearchParams(t)) : t instanceof URLSearchParams ? O.fromQuery(t) : t;
|
|
4519
|
+
return O.set(
|
|
4520
|
+
this.options,
|
|
4521
|
+
"params",
|
|
4522
|
+
O.merge(this.options.params || {}, r)
|
|
4523
|
+
), this;
|
|
4521
4524
|
}
|
|
4522
4525
|
replaceQueryParameters(t) {
|
|
4523
|
-
return O.set(
|
|
4526
|
+
return O.set(
|
|
4527
|
+
this.options,
|
|
4528
|
+
"params",
|
|
4529
|
+
typeof t == "string" ? O.fromQuery(new URLSearchParams(t)) : t instanceof URLSearchParams ? O.fromQuery(t) : t
|
|
4530
|
+
), this;
|
|
4524
4531
|
}
|
|
4525
4532
|
withData(t) {
|
|
4526
4533
|
const r = O.get(this.options, "data", {}), n = r instanceof FormData ? O.fromFormData(r) : r;
|
package/package.json
CHANGED
package/types/Http/Client.d.ts
CHANGED
|
@@ -13,8 +13,8 @@ export default class Client {
|
|
|
13
13
|
replaceHeaders(headers: Record<string, string>): this;
|
|
14
14
|
withOptions(options: RequestOptions): this;
|
|
15
15
|
replaceOptions(options: RequestOptions): this;
|
|
16
|
-
withQueryParameters(params: string | object): this;
|
|
17
|
-
replaceQueryParameters(params: string | object): this;
|
|
16
|
+
withQueryParameters(params: URLSearchParams | string | object): this;
|
|
17
|
+
replaceQueryParameters(params: URLSearchParams | string | object): this;
|
|
18
18
|
withData(data: object): this;
|
|
19
19
|
replaceData(data: object): this;
|
|
20
20
|
withBasicAuth(username: string, password: string): this;
|