@apollo/client 3.10.0 → 3.10.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/CHANGELOG.md +12 -0
- package/apollo-client.cjs +8 -3
- package/apollo-client.cjs.map +1 -1
- package/apollo-client.min.cjs +1 -1
- package/core/core.cjs +1 -1
- package/core/core.cjs.map +1 -1
- package/core/core.cjs.native.js +1 -1
- package/dev/dev.cjs +1 -1
- package/dev/dev.cjs.map +1 -1
- package/dev/dev.cjs.native.js +1 -1
- package/link/core/types.d.ts +4 -1
- package/link/core/types.js.map +1 -1
- package/link/utils/createOperation.js.map +1 -1
- package/package.json +2 -2
- package/react/ssr/RenderPromises.js +10 -15
- package/react/ssr/RenderPromises.js.map +1 -1
- package/react/ssr/ssr.cjs +8 -15
- package/react/ssr/ssr.cjs.map +1 -1
- package/react/ssr/ssr.cjs.native.js +8 -15
- package/utilities/caching/caches.d.ts +2 -2
- package/utilities/caching/caches.js +9 -4
- package/utilities/caching/caches.js.map +1 -1
- package/utilities/globals/globals.cjs +1 -1
- package/utilities/globals/globals.cjs.map +1 -1
- package/utilities/globals/globals.cjs.native.js +1 -1
- package/utilities/utilities.cjs +7 -2
- package/utilities/utilities.cjs.map +1 -1
- package/utilities/utilities.cjs.native.js +7 -2
- package/version.js +1 -1
|
@@ -171,6 +171,9 @@ function getFragmentFromSelection(selection, fragmentMap) {
|
|
|
171
171
|
|
|
172
172
|
var scheduledCleanup = new WeakSet();
|
|
173
173
|
function schedule(cache) {
|
|
174
|
+
if (cache.size <= (cache.max || -1)) {
|
|
175
|
+
return;
|
|
176
|
+
}
|
|
174
177
|
if (!scheduledCleanup.has(cache)) {
|
|
175
178
|
scheduledCleanup.add(cache);
|
|
176
179
|
setTimeout(function () {
|
|
@@ -182,16 +185,18 @@ function schedule(cache) {
|
|
|
182
185
|
var AutoCleanedWeakCache = function (max, dispose) {
|
|
183
186
|
var cache = new caches.WeakCache(max, dispose);
|
|
184
187
|
cache.set = function (key, value) {
|
|
188
|
+
var ret = caches.WeakCache.prototype.set.call(this, key, value);
|
|
185
189
|
schedule(this);
|
|
186
|
-
return
|
|
190
|
+
return ret;
|
|
187
191
|
};
|
|
188
192
|
return cache;
|
|
189
193
|
};
|
|
190
194
|
var AutoCleanedStrongCache = function (max, dispose) {
|
|
191
195
|
var cache = new caches.StrongCache(max, dispose);
|
|
192
196
|
cache.set = function (key, value) {
|
|
197
|
+
var ret = caches.StrongCache.prototype.set.call(this, key, value);
|
|
193
198
|
schedule(this);
|
|
194
|
-
return
|
|
199
|
+
return ret;
|
|
195
200
|
};
|
|
196
201
|
return cache;
|
|
197
202
|
};
|
package/version.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export var version = "3.10.
|
|
1
|
+
export var version = "3.10.1";
|
|
2
2
|
//# sourceMappingURL=version.js.map
|