Back to home

Composable Caching

The 'use cache' directive enables fine-grained caching at the function level. Combined with cacheTag, you can invalidate specific cache entries on demand.

Cached Timestamp
Uses cacheLife("default") preset from next.config.ts. Refresh the page - the timestamp stays the same until cache expires or is revalidated.

Timestamp: 2025-11-30T06:17:53.943Z

Random ID: kgxqn

Cached Quote
Uses cacheLife("hours") for longer caching. Different cache tags allow independent invalidation.
Innovation distinguishes between a leader and a follower.

How it works