mcpField
R
reatom

reatom

github.com/reatomDevelopment1.4k77 installsUpdated 1d ago
Repository

About reatom

A reference-oriented skill for developers implementing or explaining Reatom v1001. It maps tasks to sections of the bundled REFERENCE.md and provides coding conventions plus guidance on when to use related specialized skills.

Key features

  1. 01Topic-based API reference map
  2. 02Follow local code conventions
  3. 03Atom and computed-value defaults
  4. 04Async flow guidance
  5. 05Forms and routing patterns

Use cases

  1. 01Implement Reatom v1001 features
  2. 02Explain Reatom core concepts
  3. 03Find form or routing patterns
  4. 04Handle async context boundaries

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/reatom/reatom --skill reatom

After installing, type/reatomin Claude Code to confirm it loaded.

Bundled filesREFERENCE.md

Details

From the project README

Reatom

Use this skill when implementing or explaining Reatom v1001. Treat REFERENCE.md as the canonical API reference bundled with this skill.

How to use

  1. Read the sections of REFERENCE.md that match the task — do not load generic React/Solid/Vue state patterns when they conflict with the reference.
  2. Follow existing code in the touched package or example for naming, file layout, and extension style.
  3. For deep async flows (wrap, withAsyncData, withAbort, sampling, Suspense), switch to the reatom-async skill.
  4. For @reatom/jsx (native DOM JSX, mount, props, css prop), switch to the reatom-jsx skill.
  5. For pull requests, reviews, or skeptic validation of agent output, switch to the reatom-review skill.
  6. For designing, reworking, or replacing a helper, extension, or public API, switch to the reatom-api-design skill.

Section map

Use this map to open only the relevant parts of REFERENCE.md:

TopicSection
Atoms, computed, action, effect, extendCore primitives and mental model
Queries and mutationswithAsync
Async context after await / callbackswrap rules
Collections, boolean, route helpersPrimitives quick usage
Nested reactive fieldsAtomization
Subscribe error callbackSubscribe error listener
Logging, log.label, log.stateFull SPA example (logging setup)
Hooks, connect/disconnect, lazy workLifecycle and extension hooks
DOM / external eventsEvent sampling and orchestration
Hot derivationsMemoization: memo and memoKey
Fields and validationForms: base usage and reactive validation
SPA routes and loadersRouting
Search params, storageURL sync and persistence helpers
React Suspense integrationSuspense notes
Batched updatesTransactions notes
Tests and SSRSSR and testing
Upgrades from older Reatomv3 migration highlights

Deeper recipes and adapter docs live on v1001.reatom.dev under /docs/handbook/* and /docs/reference/*.

Implementation defaults

  • Named atoms, actions, computed values, and effects; factory names use the reatom* prefix.
  • Reads: zero-arg call. Writes: .set(...).
  • Idempotent reads: computed(async () => ...).extend(withAsyncData(...)).
  • Commands/mutations: action(async () => ...).extend(withAsync(...)).
  • Async boundaries that leave the Reatom frame: await wrap(promise); external callbacks: pass wrap(fn).
  • Derived state in computed; side effects in effect with explicit lifetime (route loader, init action, or mount scope — not unscoped module effects for feature work).
  • Forms (fields, validation, submit) through reatomForm / reatomField instead of hand-rolled per-field atoms and submit actions.
  • Route data through reatomRoute loaders; navigation with .go(...), links with .path(...).

When the reference and local examples disagree, prefer the reference and fix the example if it is wrong.

Comments

Markdown supported