next.js
dbd26b27 - Run unstable_cache inside a CacheStore context (#70740)

Commit
1 year ago
Run unstable_cache inside a CacheStore context (#70740) The idea is that CacheStore context will merge with Action, Prerender and Request Context but this just makes a disjoint union of the two Caches unstable_cache and "use cache". This replaces the `isUnstableCacheCallback: true` and `fetchCache: 'force-no-store'` override. Instead, we need to check manually whether we're in a cache context. This lets us avoid cloning the WorkStore context object. Now there's only one copy which makes it safer to mutate it.
Author
Parents
Loading