solid / rules
Cursor rule37k starsChanged 12 days agoMITView on GitHub
Signals engine internals — core reactivity, async, stores, optimistic lanes, and the size/testing discipline for changing them
Trending
More talk lately.about the whole repository
Who's talking about solidjs/solid
- Fireship“Solid in 100 Seconds”YouTube · May 16, 2022 · 810k views
- Kendo UI“Let’s Learn Solid JS | React Wednesdays”YouTube · Aug 12, 2021 · 8.6k views
- Unlearning Labs“🤯 SolidJS 2.0, the full course - Season 1🧪”YouTube · Nov 22, 2026 · 222 views
- Git Hype“solidjs/solid - A declarative, efficient, and flexible JavaScript library for building user…”YouTube · Nov 21, 2026 · 155 views
- microsoft/TypeScript“'identity' modifier to indicate a function's parameter-less returns should be narrowed like a value”GitHub · Jan 10, 2025 · 136 reactions
The biggest 5 of 21 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 21
Talked about on YouTube, Hacker News, GitHub and Bluesky (21 times).
On YouTube · 7
- May 16, 2022Solid in 100 Seconds — Fireship810k views · 1.1k comments
- Aug 12, 2021Let’s Learn Solid JS | React Wednesdays — Kendo UI8.6k views · 12 comments
- Nov 22, 2026🤯 SolidJS 2.0, the full course - Season 1🧪 — Unlearning Labs - There is no limit to learning222 views · 5 comments
- Nov 21, 2026solidjs/solid - A declarative, efficient, and flexible JavaScript library for building user… — Git Hype155 views
- Nov 19, 2026GitHub - solidjs/solid: A declarative, efficient, and flexible JavaScript library for building us... — GitHub Daily Trend AI Podcast134 views
2 more on YouTube
- Nov 23, 2026solidjs/solid - A declarative, efficient, and flexible JavaScript library for building user… — Git Chamber63 views
- Nov 18, 2026Solid skips the virtual DOM entirely and updates only what actually changed — GitHub Now49 views
On Hacker News · 5
- Aug 13, 2026Solid 2.0 RC: The Big <Reveal>10 points
- Oct 20, 2022Solid 1.6 – Castle in the Sky4 points
- Mar 4, 2026Solidjs releases 2.0 beta – The <Suspense> is Over3 points · 1 comment
- Aug 27, 2022Solid JS v1.5.03 points · 1 comment
- Aug 15, 2021SolidJS v1.1.01 point
On GitHub · 5
- Jan 10, 2025'identity' modifier to indicate a function's parameter-less returns should be narrowed like a value — microsoft/TypeScript136 reactions · 40 comments
- Dec 28, 2024Begin `solid-router` and `router-core` — TanStack/router22 reactions · 4 comments
- Sep 17, 2023Support writing custom renderers to use leptos anywhere — leptos-rs/leptos7 reactions · 8 comments
- Nov 11, 2024handle moving nodes — ryansolid/dom-expressions4 reactions · 5 comments
- Nov 2, 2024update types for attributes and properties — ryansolid/dom-expressions4 reactions · 20 comments
On Bluesky · 4
- Nov 7, 2026🔥 Hot Repo! 🔥 (100+ new stars) 📦 solidjs / solid ⭐ 36,261 (+139) 🗒 TypeScript A declarative, efficient, and flexible JavaScript library… — @github-trending-js.bsky.social2 likes and reposts
- Nov 19, 2026📦 solidjs / solid ⭐ 36,334 (+37) 🗒 TypeScript A declarative, efficient, and flexible JavaScript library for building user interfaces. — @github-trending-js.bsky.social1 likes and repost
- Mar 5, 2026Beta of new v2 for SolidJS. Exciting to try it out. github.com/solidjs/solid — @jqubi.bsky.social1 likes and repost
- Apr 11, 2025At a high level, how would you compare Preact to Solid [1], Inertia [2], and Ember [3]? [1] github.com/solidjs/solid [2]… — @nezteb.net0 likes and reposts · 2 replies
Where files are headingNew Cursor rule files have more rules about planning and tracking tasks, and fewer about code style.
Of the Cursor rule files we read, the 4,373 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository4 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .cursor/rules/solid-core.mdcCursor rule
- .cursor/rules/testing-patterns.mdcCursor rule
- .cursor/rules/web.mdcCursor rule
The file
We split this signals.mdc into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 27
Downstream tests consume built dist: After changing signals, pnpm --filter @solidjs/signals build and pnpm --filter solid-js build BEFORE …
≈ “Common” is an estimate: at least 1 in 5 of the 7,324 Cursor rule files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
--- description: Signals engine internals — core reactivity, async, stores, optimistic lanes, and the size/testing discipline for changing them globs: packages/signals/** alwaysApply: false --- # Solid Signals (`@solidjs/signals`) ## Source Map - **`src/core/`** — the engine: `core.ts` (nodes, read/write, recompute), `scheduler.ts` + `heap.ts` (height-ordered flush), `effect.ts`, `async.ts` (promise/iterable protocols, `handleAsync`), `verdict.ts` (`isPending`/`latest`, pending-signal companions, latest shadows), `optimistic.ts` + `lanes.ts` (optimistic lane engine — pay-for-use, installed on first use), `owner.ts`/`context.ts`, `error.ts` (`NotReadyError`), `constants.ts` (STATUS_* flags), `invariants.ts` (dev checks). - **`src/store/next/`** — the store: `store.ts` (proxy traps, targets, folds), `projection.ts`, `optimistic.ts`, `reconcile.ts`, `target.ts`. - **`src/signals.ts`**, `boundaries.ts`, `affects.ts`, `map.ts` — public primitives layered on core. ## Load-Bearing Semantics (pinned by tests and rulings — don't relearn these) - **Where the async rules live.** Read them in this order and let the earlier tier win: `docs/RULES-FUNDAMENTALS.md` (eleven immutable statements of visible behavior, `F-<n>`) → `docs/RULES-DERIVED.md` (how each applies to a shape, `D-<n>`) → `docs/SCENARIOS.md` (the screens, `S-<n>`). `docs/SPEC-ASYNC-SEMANTICS.md` is the frozen archive: the old ruling log. Never cite its A/B/C/V ids in new code, tests or PRs; cite the F-/D- successor from its banner table, and an archive entry never overrides a fundamental or a derived rule. A case that seems to need a contradiction goes to the maintainer as a screen sequence in `docs/OPEN-QUESTIONS.md`, not as a quiet amendment. - **Suspension**: an unresolved async read throws `NotReadyError`; `STATUS_UNINITIALIZED` marks never-resolved nodes and is repeatedly special-cased — first flight is NOT a refetch (no truth to keep on screen). Uninitialized sources suspend even across optimistic lanes (#3276); initialized ones serve committed stale. - **`latest()`**: subscribes through an `optimisticComputed` shadow (the reader becomes a lane consumer). Serves committed truth; suspends for tracked readers when the source is uninitialized. - **Store targets**: `.v` committed backing, `.pb` pending (draft) backing. Plain objects fold via prototype **overlay** in place; families (projection/optimistic) and arrays fold via the **clone path** (swap + parent-slot CAS). A fold finding its container privatized mid-batch must MERGE written keys onto it, not swap (#3271). `wk` is the written-keys bound (`WK_ALL` = poisoned by array length writes); `tentativePBs` marks draft-owned backings for the compose gate (#2951). - **Optimistic**: user writes become node-level overrides; drafts seed from the optimistic view (compose, not clobber). Landings staged under retaining transactions fold atomically (#3164). ## Changing This Package — Checklist 1. **Bundle size is budgeted.** Scenarios and ratcheted caps live in `scripts/size/scenarios.js`, bundled with Rolldown (run `npm run size` from `scripts/size/` after `pnpm build:js`); the floor and page caps in `scripts/size/floor-caps.json` are frozen. Every cap bump needs an audit note there. Restructuring golf is measured NO-WIN (brotli compresses repeats free; indirection adds unique tokens — 2026-09-04 notes). The winning move is **relocation into pay-for-use modules** (e.g. the optimistic module) so floor bundles don't pay. 2. **Two gates, three tiers.** Checks (strict reads, invariants, forbidden scopes, console reporting, dev-only error text) go under `__DEV__` — dev builds only. Wiring (attribution hook call sites, `_name` labels, graph edge counters, `emitDiagnostic`) goes under `__OBSERVE__` — dev AND the `dist/observe` tier, which production observability consumers select via the `observe` export condition. `__DEV__` implies `__OBSERVE__` (dev.ts asserts it). Prod folds both — free. The observe tier has its own size scenario; the prod scenarios must not move because of it. Public surface: `OBSERVE` (diagnostics channel + the attribution hook slot and interaction frame, observe-legal) vs `DEV` (devtools hooks, graph getters, console face). The attribution ENGINE is the separate `@solidjs/signals/attribution` entry (`src/attribution.ts`; prod resolves the inert `src/attribution.prod.ts`): nothing in the core may import `core/attribution.ts`, or the observe tier ships the engine to consumers that never enable it. Every build has two entries (`index` + `attribution`) sharing one module instance — the flat dev build is code-split for exactly this. Artifacts are ESM only (`dist/prod/`, `dist/observe/`, `dist/dev*.js`; no `.cjs`, no `require` branch): Node >= 22.12 `require()`s ESM, so a CJS host gets the same files — which is why no shipped module may contain a top-level `await` (`tests/dist-artifacts.test.ts` scans for it and `require`s each tier). See `documentation/archive/plans/observe-tier-plan.md`. 3. **Downstream tests consume built dist.** After changing signals, `pnpm --filter @solidjs/signals build` and `pnpm --filter solid-js build` BEFORE running `packages/solid` or `packages/web` tests — stale dist has caused false regression alarms repeatedly. 4. **Facades mirror types.** Store/signal API type changes must be applied in `packages/solid/src/client/hydration.ts` and `packages/solid/src/server/signals.ts` too. 5. Internal fields are mangled at build (`scripts/mangle-props.mjs`) in the prod and observe trees; keep the `_`-prefix convention. `_name` is the one reserved (unmangled) field — solid-js writes component labels onto signals' owners through it. `check-pure` verifies `/*#__PURE__*/` annotation count.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

