Next.js Documentation Updater
Paste the following prompt into your AI chat to install this skill:
Follow https://skillhub.cn/install/skillhub.md to install @user_e40a4360/documentation-updater.
About this skill
Problem Context
In the Next.js repository, code changes often ripple into API references, configuration pages, and guides. Maintainers reviewing PRs need to determine which docs are affected, whether a page is Pages Router shared content, and where new feature documentation should live. This skill turns that “diff-to-documentation” path into a repeatable workflow.
How It Works
- It starts with
git diff canary...HEAD --statto inspect changed files, then maps them to docs usingreferences/CODE-TO-DOCS-MAPPING.mdand directories such asdocs/01-app/03-api-reference/. - For existing docs, it reads the current structure, frontmatter, and router-specific content, then identifies new props, behavior changes, deprecations, and missing examples. Each proposed edit is confirmed before being applied.
- For new features, it selects the right doc type—component, function, config, guide, or file convention—uses kebab-case naming, applies the API Reference or Guide template, and adds related frontmatter links.
- It validates frontmatter, code block filenames, TypeScript/JavaScript switchers, props tables, and related links, and runs
pnpm lint.
Scope and Caveats
This skill is aimed at Next.js documentation maintenance, especially App Router pages and shared Pages Router content. It relies on repository references such as references/DOC-CONVENTIONS.md and the code-to-docs mapping; if those files are incomplete, the output will depend on existing doc structure. It asks for confirmation before edits but still requires human judgment for API semantics and migration guidance.
Editor's note
Written for AI Agent Hub. This is separate from the publisher description above.
What problem it solves
Docs drift from the code on a branch. This skill targets Next.js documentation so a maintainer can review a docs diff after a real change. The problem is stale docs in that framework, not a general wiki cleanup.
Who it is for
Maintainers of a Next.js repo whose docs live in files you can diff, working on a branch that already contains the code change.
Who should skip it
Skip it for a different framework. A prompt that assumes Next.js file layout will invent routes everywhere else. Skip it if you wanted a memory of decisions across Harness sessions. That is a memory plugin or a markdown file, discussed on the knowledge-management shelf. Skip "reorganize the whole vault."
First three steps
- On a branch, add one comment or one small behavior a human would expect the docs to mention. Commit it.
- Ask the skill to update docs only, not source.
- Read the diff. Docs-only and accurate means keep it. A rewritten component means revert and remove the skill. The install guide uses this trial as the picture of removal, including rules files the skill may have written into the repo.
Alternatives on this site
Write the paragraph yourself if the change is one sentence. A content skill will be less aware of the framework and more likely to add marketing adjectives you do not want in API docs.
Questions
Will teammates get this prompt? If it wrote a rules file and you commit it, yes. Search the diff for the prompt before you push.
Does it watch the repo continuously? Not from this directory. It runs when you invoke it. If a rules file means it runs on every chat, that is the settings layer, and you should see it in the diff before you call the skill installed.
Use Cases
- When reviewing a component PR, update the component API reference after image.tsx props change.
- When a config PR changes shared config code, update the matching App Router config documentation.
- When adding a new function, scaffold an API reference with frontmatter, examples, and related links.
- Before committing docs, validate frontmatter, code block filenames, TS/JS switchers, and pnpm lint.
Best For
- Next.js documentation maintainers reviewing PRs need to identify affected API pages.
- App Router component engineers updating props references need to add tables and examples.
- Feature authors onboarding new APIs need to scaffold correctly formatted docs.
- Contributors handling shared Pages Router content need to edit the right source file.
Related Skills
Battle-tested standards and tooling for org knowledge bases: LLM Wiki conventions, four-layer indexing, and optional local Ollama agentic RAG.
Turn mp.weixin.qq.com articles into Markdown with verbatim body text, original image CDN URLs, and explicit video/audio markers.
Initialize or audit research repos for findability, reproducibility, traceability, and deliverables while isolating AI drafts from reviewed assets.
Timed literature monitoring for clinicians and researchers: multi-source fetch, keyword filtering, LLM scoring and abstract-based summaries, with push and traceable archives.
Reader reviews
No approved reader reviews on this listing yet. Yours can be the first.