Const
For usage with cacheComponents: true, and defineLive:
cacheComponents: true
defineLive
// next.config.tsimport type {NextConfig} from 'next'import {sanity} from 'next-sanity/live/cache-life'const nextConfig: NextConfig = { cacheComponents: true, cacheLife: { default: sanity, }}export default nextConfig Copy
// next.config.tsimport type {NextConfig} from 'next'import {sanity} from 'next-sanity/live/cache-life'const nextConfig: NextConfig = { cacheComponents: true, cacheLife: { default: sanity, }}export default nextConfig
Readonly
Sanity Live handles on-demand revalidation, so the default 15min time-based revalidation is too short
For usage with
cacheComponents: true, anddefineLive: