v3.6.0
Changes
- #843
64ee6845dd38d8b543ecbe1cda807ae1f9a37a16
- Introduce support for the composable cache - #844
1ed738fed4184fe1f509c17d87239a6ec89cd014
- Fix middleware search params with multiple values - #833
3b979a2c18f2cf3f930f89587158fda29645fbbc
- pass revalidate for ISR/SSG cache - #839
de53c4d2458f22d056320b71bd28567b8ac6ec04
Thanks @james-elicx! - fix edge middleware path on windows
BREAKING CHANGE
This only affects custom overrides for the incremental or tag cache
The interface for the Incremental cache has changed. The new interface use a Cache type instead of a boolean to distinguish between the different types of caches. It also includes a new Cache type for the composable cache. The new interface is as follows:
export type CacheEntryType = "cache" | "fetch" | "composable";
export type IncrementalCache = {
get<CacheType extends CacheEntryType = "cache">(
key: string,
cacheType?: CacheType,
): Promise<WithLastModified<CacheValue<CacheType>> | null>;
set<CacheType extends CacheEntryType = "cache">(
key: string,
value: CacheValue<CacheType>,
isFetch?: CacheType,
): Promise<void>;
delete(key: string): Promise<void>;
name: string;
};
NextModeTagCache also get a new function getLastRevalidated
used for the composable cache:
getLastRevalidated(tags: string[]): Promise<number>;