cache-components

Community

Proactive guidance for Next.js Cache Components.

AuthorAngelP17
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This Skill provides expert guidance for implementing Next.js Cache Components and Partial Prerendering (PPR). It auto-activates in projects that set cacheComponents: true in next.config, helping teams co-locate caching decisions with components and achieve a static shell plus dynamic streaming experience.

Core Features & Use Cases

  • Proactive activation when cacheComponents is detected in next.config.ts/next.config.js, ensuring patterns are applied across React Server Components, data fetching, and Server Actions.
  • Guidance on using the 'use cache' directive, cacheLife, cacheTag, updateTag, revalidateTag, and revalidatePath for precise invalidation, shared caches, and SWR-style background refresh.
  • Strategies for building pages with static shells, cached components, and Suspense-wrapped dynamic sections, including generateStaticParams subshells and multi-level caching.
  • Built-in guidance for debugging, performance tuning, and avoiding common anti-patterns to maximize cache effectiveness.

Quick Start

Enable Cache Components in next.config by setting cacheComponents: true, wrap data fetching with 'use cache' and corresponding cache APIs, tag caches with cacheTag, invalidate with updateTag or revalidateTag, and compose pages with a static shell plus cached blocks and Suspense for dynamic content.

Dependency Matrix

Required Modules

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: cache-components
Download link: https://github.com/AngelP17/factoryops-console/archive/main.zip#cache-components

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.