IterableWeakSet, IterableWeakMap, and WeakValueMap provide iterable weak collections whose entries disappear automatically when their objects are garbage collected—perfect for caches and registries in any JavaScript runtime.
A LRU cache built on WeakRefs and FinalizationRegistry