# _template

\_template — a rule-file scaffold with fields for its title and impact, plus sections for contrasting incorrect and correct code.

- rule · `type=rule` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline · ★ 1064 repo stars
- Author: jarrodwatts
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/jarrodwatts/claude-code-config/tree/HEAD/skills/vercel-react-best-practices/rules/_template.md
- Updated: 2026-01-21
- Security check: automated, 2026-11-16 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/rules/template

## What it does

\`_template` is a file outline, not a ready-made instruction for an agent. It provides space for a title, an impact level, a short rationale, contrasting code samples, and a reference link. Replace the sample labels and code with details from the rule you want to write.

For Claude Code, put the file at `.claude/rules/_template.md`. Placeholders such as `Rule Title Here` and `example()` do not define a specific agent behavior. Write the rule itself before using the scaffold as a project instruction.

## Install

### Claude Code (native platform)

**Manually: put the files in place**
- File: `.claude/rules/_template.md` — The paths frontmatter field limits the files

### Codex

**AGENTS.md**
- Codex reads AGENTS.md: paste the rule text there

### Cursor

**Manually: put the files in place**
- File: `.cursor/rules/_template.mdc` — Frontmatter: description, globs, alwaysApply

### GitHub Copilot

**Manually: put the files in place**
- File: `.github/instructions/_template.instructions.md` — The applyTo field sets which files it applies to

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/rules/_template.md`

### Cline

**Manually: put the files in place**
- File: `.clinerules/_template.md`

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/jarrodwatts/claude-code-config/tree/HEAD/skills/vercel-react-best-practices/rules/_template.md

## When to use it
- create an outline for a rule file
- record a rule’s impact and rationale
- contrast incorrect and correct code
- add a reference link to a rule

## Example prompts
- Draft a Claude Code rule about error handling using `_template`.
- Fill in `_template` with a rule for code formatting and replace its sample content.
- Create a rule file that compares incorrect and correct code using the `_template` structure.

## Similar
- [list-performance-callbacks](https://affpapa.org/en/nevibecode/rules/list-performance-callbacks.md) — rule · ★ 88 repo stars
- [ppt-template-creator](https://affpapa.org/en/nevibecode/skills/ppt-template-creator.md) — skill · 2400 installs
- [template-selector](https://affpapa.org/en/nevibecode/skills/template-selector.md) — skill · 175 installs
- [adr-byo-template](https://affpapa.org/en/nevibecode/rules/adr-byo-template.md) — rule · ★ 1627 repo stars
- [recipe-create-doc-from-template](https://affpapa.org/en/nevibecode/skills/recipe-create-doc-from-template.md) — skill · 31800 installs
- [documentation-template](https://affpapa.org/en/nevibecode/skills/documentation-template.md) — skill · 2500 installs

From the same set: [jarrodwatts/claude-code-config](https://affpapa.org/en/nevibecode/by/jarrodwatts/claude-code-config.md) — 20 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
