Agent skill

Rule Writing

by millionco in millionco/react-doctor

Implement React Doctor rules from a validated contract. An agent skill from millionco/react-doctor.

Custom licenceAuto-check passedDevelopment

Install Rule Writing

skills CLI
$ npx skills add millionco/react-doctor --skill rule-writing -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install millionco/react-doctor rule-writing --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/millionco/react-doctor.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/rule-writing .claude/skills/rule-writing && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
rule-writing
GitHub stars
15k
Token cost
~522 tokens
SKILL.md length
211 words
Files
1
Skills in repo
13
Repo updated
First seen
Licence
Custom licence

At a glance

Implement React Doctor rules from a validated contract. An agent skill from millionco/react-doctor.

  • Works in 8 steps: Write detector pseudocode. → Add adversarial valid and invalid tests. → Implement only the contract's supported… → …
  • Writing oxlint rules
  • SKILL.md covers Plan the detector, Implement and test, Run repository checks and Report the implementation
  • Calls bunx

What it does

Rule Writing is an agent skill from millionco/react-doctor. Implement React Doctor rules from a validated contract. Use when writing oxlint rules, planning syntax or control-flow detection, designing adversarial tests, reusing syntax tree utilities, or updating rule registration.

Its SKILL.md is about 520 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development. It works with React. The repository describes itself as: Your agent writes bad React. This catches it.

When your agent uses it

  • Writing oxlint rules
  • Planning syntax
  • Control-flow detection
  • Designing adversarial tests

Example prompts

  • “/rule-writing”

Workflow steps

8 steps, taken from the first numbered list in SKILL.md.

  1. Write detector pseudocode.
  2. Add adversarial valid and invalid tests.
  3. Implement only the contract's supported behavior.
  4. Reuse utilities before creating new ones.
  5. Update generated registration with repository commands.
  6. Run focused tests and package checks.
  7. Use rde-eval when real-code feedback could expose noise.
  8. Hand the finished change to rule-validate.

What it can do on your machine

Read from SKILL.md and the folder at commit 5b301c9. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • bunx

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use bunx, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Rule Writing loads about 522 tokens when it runs. Until then it costs about 58 tokens; SKILL.md has 211 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~58
When it runs · the whole SKILL.md, loaded when a task matches
~522

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

Its licence (Custom licence) doesn't allow us to republish the file, so here is its outline and opening line. It has 211 words (~522 tokens).

“Implement the rule-research contract. If none exists, define a compact contract before editing.”

— opening of SKILL.md by millionco, Custom licence
name
rule-writing

Read the full SKILL.md on GitHub

Files

Just SKILL.md in .agents/skills/rule-writing of millionco/react-doctor.

Open the folder on GitHubat commit 5b301c9

Compare with similar skills

Rule Writing next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Rule Writing compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Rule Writing this skillmillionco/react-doctor15k—~522Automated safety check: PassCustom licence
Vercel Composition Patternssupabase/supabase111k58 repos~726Automated safety check: PassMIT
Electron Multi-Process ArchitectureiOfficeAI/AionUi33k1 repos~1.8kAutomated safety check: PassApache-2.0
Nx Generatenomcopter/react-mosaic4.8k7 repos~1.9kAutomated safety check: PassCustom licence
@pierre/diffs Code Renderingpierrecomputer/pierre6.3k2 repos~803Automated safety check: PassApache-2.0
OpenTUI Terminal Interfacescline/cline70k—~1.9kAutomated safety check: PassApache-2.0

Similar skills

  • Official

    React composition patterns that scale. An agent skill from supabase/supabase.

    111k GitHub starsUsed in 58 repos~726 tokens
    DevelopmentAuto-check passed
  • Tells the agent where new code belongs in an Electron multi-process project and which APIs each process may use, with rules for new bridges, services, agents and workers.

    33k GitHub starsUsed in 1 repo~1.8k tokens
    DevelopmentAuto-check passed
  • Nx Generate

    nomcopter/react-mosaic

    Generate code using nx generators. An agent skill from nomcopter/react-mosaic.

    4.8k GitHub starsUsed in 7 repos~1.9k tokens
    DevelopmentAuto-check passed
  • @pierre/diffs Code Rendering

    pierrecomputer/pierre

    Guides an agent through using @pierre/diffs to render syntax-highlighted files and diffs, and to build editing and review surfaces in React or plain JavaScript.

    6.3k GitHub starsUsed in 2 repos~803 tokens
    DevelopmentAuto-check passed
  • Helps build terminal user interfaces with OpenTUI using its core imperative API or its React and Solid reconcilers, with references for layout, keyboard, animation and testing.

    70k GitHub stars~1.9k tokensUpdated today
    DevelopmentAuto-check passed
  • Claude Code Skill

    codeaashu/claude-code

    Development conventions and architecture guide for the Claude Code CLI repository.

    3.4k GitHub starsUsed in 1 repo~2.7k tokens
    DevelopmentAuto-check passed

More from millionco/react-doctor

All 13 skills in this repo
  • Run Parity

    millionco/react-doctor

    Compare React Doctor diagnostics for a GitHub pull request (PR) with Vercel Sandbox.

    15k GitHub stars~4.1k tokensUpdated today
    Auto-check passed
  • Benchmark Fp Fn Audit

    millionco/react-doctor

    Audit React Doctor against ReactBench or similar diagnostic benchmark corpora for confirmed false positives, false negatives, taxonomy gaps, and verifier artifacts.

    15k GitHub stars~2k tokensUpdated today
    Auto-check passed
  • Deslop

    millionco/react-doctor

    Simplify and refine recently modified code while preserving functionality.

    15k GitHub stars~1.2k tokensUpdated today
    Auto-check passed
  • Find Similar Functions

    millionco/react-doctor

    Use truffler to find similar or pre-existing JavaScript/TypeScript symbols before implementing new code, especially helpers, utilities, parsers, formatters, scanners, fuzzy matchers, and other…

    15k GitHub stars~1.2k tokensUpdated today
    Auto-check passed
  • Improve Threejs

    millionco/react-doctor

    Audit and fix Three.js and React Three Fiber apps for frame-loop performance, GPU memory leaks, scene-graph correctness, and visual defects like z-fighting, shadow acne, wrong color space, and…

    15k GitHub stars~2.3k tokensUpdated today
    Auto-check passed
  • Performance

    millionco/react-doctor

    Diagnose React runtime performance with React Doctor traces, live render outlines, Long Animation Frames, interaction timing, and component render evidence.

    15k GitHub stars~1.2k tokensUpdated today
    Auto-check passed

Works with

Categories

Questions about Rule Writing

What does Rule Writing do?

Implement React Doctor rules from a validated contract. An agent skill from millionco/react-doctor. Rule Writing is an agent skill from millionco/react-doctor. Implement React Doctor rules from a validated contract.

When should I use Rule Writing?

Rule Writing fits situations like: writing oxlint rules; planning syntax; control-flow detection; designing adversarial tests.

How do I install Rule Writing in Claude Code?

Run `npx skills add millionco/react-doctor --skill rule-writing -a claude-code`. Or copy the skill folder (.agents/skills/rule-writing in millionco/react-doctor) into .claude/skills/rule-writing in your project. Claude Code loads it when a task matches its description.

How do I install Rule Writing in Codex?

Run `npx skills add millionco/react-doctor --skill rule-writing -a codex`. Or copy the skill folder (.agents/skills/rule-writing in millionco/react-doctor) into .agents/skills/rule-writing in your project. Codex loads it when a task matches its description.

Can I use Rule Writing in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add millionco/react-doctor --skill rule-writing -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/rule-writing, .gemini/skills/rule-writing, .github/skills/rule-writing and .opencode/skills/rule-writing in your project.

What does Rule Writing need to run?

Going by SKILL.md and its folder, Rule Writing needs the command-line tools its instructions call (bunx).

Does Rule Writing access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Rule Writing safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Rule Writing use?

Rule Writing has a licence file (the repository's licence) that doesn't match a standard licence. Read it on GitHub before reusing the skill.

How many tokens does Rule Writing use?

About 522 tokens (SKILL.md is roughly 2.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Rule Writing?

Skills that share tags, products or a category with Rule Writing: Vercel Composition Patterns (supabase/supabase, 111k stars), Electron Multi-Process Architecture (iOfficeAI/AionUi, 33k stars), Nx Generate (nomcopter/react-mosaic, 4.8k stars) and @pierre/diffs Code Rendering (pierrecomputer/pierre, 6.3k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Rule Writing?

millionco (a GitHub organization) maintains it in millionco/react-doctor, which has 14,992 GitHub stars. The repository holds 13 skills in this directory. The repository was last updated on October 10, 2026.

Source: millionco/react-doctor on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.