solidjs-knowledge-patch
SolidJS changes since training cutoff (latest: 2.0 beta, SolidStart 1.1) -- Solid 2.0 rewrites reactivity with microtask batching, split effects, async-first computations, Loading/Errored boundaries, draft-first stores, actions with optimistic updates, and DOM model cleanup. Load before working with SolidJS.
What this skill does
# SolidJS 1.9+ / 2.0 Beta Knowledge Patch
Claude's baseline knowledge covers SolidJS through 1.8.x. This skill provides features from 1.9 (Sep 2024) through the 2.0 beta (Mar 2026), plus SolidStart 1.0-1.1.
## Quick Reference
### API Renames (2.0)
| 1.x | 2.0 |
|-----|-----|
| `Suspense` | `Loading` |
| `ErrorBoundary` | `Errored` |
| `mergeProps` | `merge` |
| `splitProps` | `omit` |
| `unwrap` | `snapshot` |
| `onMount` | `onSettled` |
| `classList` | `class` (object/array) |
| `createResource` | async `createMemo` + `Loading` |
| `createSelector` | `createProjection` |
| `createComputed` | split `createEffect` or `createSignal(fn)` |
| `batch()` | `flush()` |
| `use:directive` | `ref={directive(opts)}` |
| `Context.Provider` | `<Context value={...}>` |
### Import Changes (2.0)
| 1.x | 2.0 |
|-----|-----|
| `solid-js/web` | `@solidjs/web` |
| `solid-js/store` | `solid-js` (stores merged into core) |
| `solid-js/h` | `@solidjs/h` |
| `solid-js/html` | `@solidjs/html` |
| `solid-js/universal` | `@solidjs/universal` |
### Batching & Reads (2.0)
```tsx
const [count, setCount] = createSignal(0);
setCount(1);
count(); // still 0 -- reads return last committed value
flush();
count(); // now 1
```
See `references/reactivity-effects.md` for split effects, `onSettled`, dev warnings.
### Async Data (2.0)
| Pattern | Code |
|---------|------|
| Fetch data | `const user = createMemo(() => fetchUser(id()));` |
| Loading boundary | `<Loading fallback={<Spinner />}><Profile /></Loading>` |
| Revalidation check | `const pending = () => isPending(() => users());` |
| Peek stale value | `const val = () => latest(signal);` |
| Refresh after mutation | `refresh(derivedStore);` |
See `references/async-actions.md` for actions, optimistic updates, `refresh`.
### Stores (2.0)
```tsx
// Draft-first setter (produce-style)
const [store, setStore] = createStore({ user: { name: 'A' } });
setStore((s) => {
s.user.name = 'B';
});
// 1.x-style path setter via storePath helper
setStore(storePath('user', 'name', 'B'));
// Snapshot for serialization
const plain = snapshot(store);
```
See `references/stores.md` for derived stores, projections, `deep()`, `merge`, `omit`.
### Control Flow (2.0)
```tsx
// For with accessors (keyed by identity, the default)
<For each={items()}>
{(item, i) => <Row item={item()} index={i()} />}
</For>
// Index-style (reuse by position)
<For each={items()} keyed={false}>
{(item, i) => <Row item={item()} index={i()} />}
</For>
// Repeat (no diffing, for skeletons/ranges)
<Repeat count={10}>{(i) => <Skeleton index={i} />}</Repeat>
```
See `references/control-flow-dom.md` for `Show`, `Switch/Match`, `Errored`, DOM changes.
### SolidStart 1.0-1.1
| Feature | Detail |
|---------|--------|
| Package | `@solidjs/start` |
| Routing | File-based via `<FileRoutes />` + `@solidjs/router` |
| Dynamic routes | `[id].tsx`, optional `[[id]].tsx`, catch-all `[...path].tsx` |
| Route groups | `(groupName)/` folders |
| Nested layouts | `blog.tsx` + `blog/` directory |
| API routes | Files in `routes/` exporting HTTP methods |
| Vite 6 | Supported since SolidStart 1.1 |
| Roadmap | SolidStart 2.0 replaces Vinxi with pure Vite ("DeVinxi") |
See `references/solidstart.md` for routing details, route config, preload.
## Reference Files
| File | Contents |
|------|----------|
| `reactivity-effects.md` | Split effects, `flush`, `onSettled`, dev warnings, ownership |
| `async-actions.md` | Async computations, `Loading`, `isPending`, actions, optimistic updates |
| `stores.md` | Draft-first setters, `storePath`, projections, `snapshot`, `merge`, `omit` |
| `control-flow-dom.md` | `For`/`Repeat`/`Show`/`Switch`, `Loading`/`Errored`, DOM attributes, directives |
| `solidstart.md` | SolidStart 1.0-1.1, file routing, layouts, DeVinxi roadmap |
## Critical Knowledge
### Solid 1.9 Changes
New features in 1.9 (the last 1.x release before 2.0):
- `bool:` attribute namespace for custom elements: `<my-el bool:enable={flag()} />`
- `on:` with `handleEvent` objects for advanced event options (passive, once, capture):
```tsx
<div
on:wheel={{
handleEvent(e) {
e.preventDefault();
},
passive: false,
}}
/>;
```
- Better JSX validation via JSDOM (detects invalid nesting like `<a>` inside `<a>`)
- `oncapture:` deprecated in favor of `on:` with event objects
### Top-Level Read Warning (2.0 dev)
Solid 2.0 warns in dev when you read reactive values at the top level of a component body. This catches a class of bugs where reactivity is accidentally lost.
```tsx
// BAD: warns -- destructuring loses reactivity
function Bad({ title }) {
return <h1>{title}</h1>;
}
// GOOD: keep props object
function Good(props) {
return <h1>{props.title}</h1>;
}
// GOOD: intentional one-time read
function OneTime(props) {
const t = untrack(() => props.title);
return <h1>{t}</h1>;
}
```
### Write-Under-Scope Warning (2.0 dev)
Writing to signals inside reactive scopes (effects, memos, component body) warns. Derive instead of writing back.
```tsx
// BAD: warns
createMemo(() => setDoubled(count() * 2));
// GOOD: derive
const doubled = createMemo(() => count() * 2);
// Escape hatch for internal state only
const [ref, setRef] = createSignal(null, { pureWrite: true });
```
### Context Provider Simplification (2.0)
```tsx
const Theme = createContext('light');
// 1.x
<Theme.Provider value="dark"><Page /></Theme.Provider>
// 2.0 -- context IS the provider
<Theme value="dark"><Page /></Theme>
```
### Directives via ref (2.0)
```tsx
// 1.x
<button use:tooltip={{ content: 'Save' }} />
// 2.0 -- ref with directive factory
<button ref={tooltip({ content: 'Save' })} />
// Multiple directives via array
<button ref={[autofocus, tooltip({ content: 'Save' })]} />
```
Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.