dotfiles: Skill for Claude Code

.claude/skills/no-useeffect/SKILL.md

no-useeffect is a skill for Claude Code from ahonn/dotfiles. It costs 22 tokens per session (620 once invoked), scanned A, original, MIT.

A React coding rule that bans direct calls to useEffect and lists alternative patterns for derived values, event handling, data fetching, and one-time external synchronization.

In plain words
What is it for?
Use it when writing, reviewing, or refactoring React components that contain useEffect calls.
Why use it?
It prevents unnecessary render cycles, effect chains, and synchronization bugs caused by using effects for work that can happen elsewhere.

Skill for Claude Code

Written for Claude Code: installed under .claude/. Also seen: mentions AGENTS.md.

This is ahonn/dotfiles's own configuration. It tells Claude Code how to work on dotfiles itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything dotfiles configures →

Reuse

Borrowing it

Nothing to install: this file belongs to ahonn/dotfiles. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/ahonn/dotfiles/master/.claude/skills/no-useeffect/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/ahonn/dotfiles

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for no-useeffect

README.md
[![agentmods](https://agentmods.dev/badge/skills/ahonn/dotfiles/no-useeffect/github.svg)](https://agentmods.dev/skills/ahonn/dotfiles/no-useeffect)
Your own site
<a href="https://agentmods.dev/skills/ahonn/dotfiles/no-useeffect"><img src="https://agentmods.dev/badge/skills/ahonn/dotfiles/no-useeffect/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for no-useeffect

Your own site · 80×15
<a href="https://agentmods.dev/skills/ahonn/dotfiles/no-useeffect"><img src="https://agentmods.dev/badge/skills/ahonn/dotfiles/no-useeffect.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 22 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 620 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00022 $0.00620
Opus 5.5 $0.00009 $0.00248
Sonnet 5.5 $0.00004 $0.00124
Haiku 4.5 $0.00002 $0.00062

Measured 20d ago against content hash 5a80f33677f0, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

no-useeffect scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 20d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/no-useeffect/SKILL.md · 37 lines

How it starts

The opening of the file, as written. The whole thing — 37 lines — stays where its author put it; the contents beside it link to each section on GitHub.

No Direct useEffect

Do not call useEffect directly in application components or feature hooks. Use the project's approved primitives and lifecycle architecture. This is the user's coding preference; it does not imply React has no legitimate effect use cases.

Inspect project guidance and lint exemptions first. A project may permit direct effects inside designated low-level primitives such as useMountEffect, useSharedValueSync, or useDelayedFlag. Respect those explicit boundaries instead of imposing a single global wrapper. Do not introduce an unapproved wrapper simply to evade the ban.

Choose by the behavior needed

Need Preferred approach
Compute a value from props or state Derive during render; memoize only when the computation warrants it
Respond to a user action Run the action in its event handler or store action
Fetch and cache server data Use the project's query library or framework loader
Read a mutable external store Use its supported hook or useSyncExternalStore
Initialize an external resource for a mount Use the approved mount primitive with cleanup
Synchronize a changing input with an external resource Use an approved reactive primitive or the resource's lifecycle API
Reset all local state for a new entity Use key when a full remount matches the intended behavior

These are decision aids, not an exhaustive replacement theorem. When none fits, inspect the external system's lifecycle and existing primitives before proposing a design. Follow global AGENTS.md authorization rules; this skill adds no confirmation requirement for established project patterns.

Preserve semantics during refactoring

  • Derived state should have a single source of truth. Avoid storing values that can be computed from current inputs.
  • User-triggered work belongs in the action path; do not relay it through a state flag and an effect.
  • Use query keys and options consistent with the installed data library. Cancellation requires the query function or transport to honor the relevant signal; a library alone does not make every request cancellable.
  • A mount primitive is appropriate only when setup belongs to that mounted instance. It is not a drop-in replacement for synchronization that must react to changing dependencies.
  • Mount setup may run again after remounts and during development lifecycle checks. Return cleanup, release subscriptions and resources, and handle async completion after disposal.
  • A key resets the entire subtree, including focus, playback, animations, and local state. Use it only when those resets are intended; do not remount solely to avoid reasoning about updates.
  • Do not replace useEffect with useLayoutEffect merely to bypass the rule. Use the project's approved layout mechanism only when synchronous layout work is actually required.

Read the full file on GitHub · 37 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 20d ago Changed · -121 lines · -91 tokens per session 5a80f33677f0
  2. 1mo ago First seen · 158 lines · 113 tokens per session scan A 7f6e2b57c524

Subscribe to this mod's changes

no-useeffect is a skill published in the GitHub repository ahonn/dotfiles (63 stars, last pushed 6d ago), licensed MIT. It adds 22 tokens to every session and 620 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

pr-review

Intelligent PR code review with dynamic agent allocation based on change types. Analyzes PR changes and generates targeted review tasks.

magic3007/dotfiles · 28 tokens

analyze-pr

Analyze a GitHub/GitLab Pull Request by fetching its diff, reading its web description, and generating a comprehensive document. Use when the user provides a PR link and wants to understand what changes the PR introduces, or asks to review/analyze/summarize a pull request.

magic3007/dotfiles · 60 tokens

assess-quality

Foundational quality framework: the five questions (readable, easy to start, expands without bloat, consistent, intentional) every other dev skill is judged against, plus the dual-audience and workshop principles. Use when onboarding to a project, defining a quality bar, setting an assessment checklist, or arbitrating…

urmzd/dotfiles · 120 tokens

merge-ready

Drive an existing pull request to a mergeable state: get CI green, resolve merge conflicts with the base branch, address and resolve review comments, trigger required bot reviews/approvals (e.g. commenting '@claude review'), link associated issues, and clean up the PR title and description. Ends with a readiness…

urmzd/dotfiles · 208 tokens

check-project

Validate project structure against scaffold conventions -- check for required files, CI consistency, documentation completeness, sub-package/workspace members, and optional directory usage, reporting PASS/WARN/FAIL with fix suggestions. Use to audit an existing project or verify a scaffold was applied correctly. Do…

urmzd/dotfiles · 82 tokens

review-diff

Standardized review of the CURRENT working-tree changes -- staged, unstaged, and untracked -- against an explicit five-dimension rubric (correctness, security, tests, scope-creep, conventions). Emits a prioritized findings list, each with file:line, severity, and a suggested fix. Read-only: it reviews and reports, it…

urmzd/dotfiles · 170 tokens