@snail-js/api 0.1.0 → 0.1.1
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/snail-api.mjs +2 -2
- package/dist/snail-api.umd.js +2 -2
- package/package.json +1 -1
package/dist/snail-api.mjs
CHANGED
|
@@ -108,7 +108,7 @@ class Api {
|
|
|
108
108
|
var _a;
|
|
109
109
|
const instance = this;
|
|
110
110
|
instance.name = config == null ? void 0 : config.name;
|
|
111
|
-
instance.name
|
|
111
|
+
instance.name && this.context.cacheSource.push(this);
|
|
112
112
|
instance.hitSource = config == null ? void 0 : config.hitSource;
|
|
113
113
|
instance.method = method;
|
|
114
114
|
instance.url = url;
|
|
@@ -2869,7 +2869,7 @@ class Snail {
|
|
|
2869
2869
|
__publicField(this, "versioning");
|
|
2870
2870
|
__publicField(this, "options");
|
|
2871
2871
|
__publicField(this, "cacheStorage");
|
|
2872
|
-
__publicField(this, "cacheSource");
|
|
2872
|
+
__publicField(this, "cacheSource", []);
|
|
2873
2873
|
const instance = this;
|
|
2874
2874
|
const SnailOptions = {
|
|
2875
2875
|
...DEFAULT_CONFIG,
|
package/dist/snail-api.umd.js
CHANGED
|
@@ -112,7 +112,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
112
112
|
var _a;
|
|
113
113
|
const instance = this;
|
|
114
114
|
instance.name = config == null ? void 0 : config.name;
|
|
115
|
-
instance.name
|
|
115
|
+
instance.name && this.context.cacheSource.push(this);
|
|
116
116
|
instance.hitSource = config == null ? void 0 : config.hitSource;
|
|
117
117
|
instance.method = method;
|
|
118
118
|
instance.url = url;
|
|
@@ -2873,7 +2873,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2873
2873
|
__publicField(this, "versioning");
|
|
2874
2874
|
__publicField(this, "options");
|
|
2875
2875
|
__publicField(this, "cacheStorage");
|
|
2876
|
-
__publicField(this, "cacheSource");
|
|
2876
|
+
__publicField(this, "cacheSource", []);
|
|
2877
2877
|
const instance = this;
|
|
2878
2878
|
const SnailOptions = {
|
|
2879
2879
|
...DEFAULT_CONFIG,
|