mcpbeat Sign in

Nextjs SEO Foundations Agent Skill

Next.js 14 应用的生产级 SEO 工程化规范 (Metadata, Schema, Performance)

577 tokens
context cost
the whole folder, loaded on every use
2
files
instructions only
0
copies elsewhere
how many repositories repackaged it
311
stars on the repo
on the repository, not the skill itself

Install

one command, takes just this skill from the repository
npx skills add https://github.com/kennyzir/7deer_skills --skill nextjs-seo-foundations

What comes with it

478 bytes besides the instruction
resources/StructuredData.tsx

The instruction itself

11 sections, as written by the author

🚀 Next.js SEO Foundations

Role: SEO Engineer (SEO 工程师)

Core Function: 确保代码符合 Technical SEO 工业标准。

When This Skill Applies

  • 当用户要求 "Check SEO" 或 "Optimize page" 时。
  • 当编写 generateMetadata 函数时。
  • 当添加 StructuredData 或 JSON-LD 时。
  • 当进行代码审查 (Code Review) 涉及性能指标 (LCP/CLS) 时。

Instructions

本 Skill 定义了构建高流量 Next.js 站点的工程标准

1. Metadata 架构 (The Logic of Tags)

1.1 动态标题策略
  • Rule: 必须包含 Month Year 以保持新鲜度。
  • Code Pattern:
    export async function generateMetadata(): Promise<Metadata> {
      const date = new Date();
      const monthYear = date.toLocaleDateString('en-US', { month: 'long', year: 'numeric' });
      return { title: `Codes (${monthYear}) ...` }
    }
1.2 Canonical URL 强制性
  • Fatal Error: 缺少 Canonical 会导致权重分散。
  • Fix: 统一使用带尾部斜杠的绝对路径。

2. 结构化数据体系 (Schema Graph)

任何高流量页面 (Hub Page) 必须包含 Schema 组合拳:

  • BreadcrumbList: 层级结构。
  • FAQPage: 抢占 PAA 区域 (>= 5 Questions)。
  • VideoGame: 产品本体。

3. 性能即 SEO (Performance as SEO)

3.1 图片优化 (LCP)
  • Rule: 首屏大图 (Hero Image) 必须添加 priority 属性。
3.2 交互延迟 (FID/INP)
  • Optimization: 将非首屏交互组件 (Chart, Calculator) 使用 next/dynamic 延迟加载。

Commands

  • /audit-seo [url]: 运行 SEO 完整性检查。

How to use it

Copy the folder

Take kennyzir/nextjs-seo-foundations from the repository into ~/.claude/skills for personal use, or into .claude/skills inside a project.

Check the name does not clash

The agent identifies a skill by the name field in its header. Two skills with the same name cannot sit side by side — one of them will be ignored.