← ClaudeAtlas

javascriptlisted

Write and review JavaScript: declarations, equality and coercion, functions, objects, iteration, classes, async and promise semantics, ES modules, regular expressions, JSDoc typing, and the ECMAScript features a project's engine baseline permits.
xobotyi/cc-foundry · ★ 23 · AI & Automation · score 84
Install: claude install-skill xobotyi/cc-foundry
**JavaScript fails by continuing.** A mismatched type is coerced, a missing property is `undefined`, a rejected promise nobody watched is a warning. None of it reports itself, so the discipline is to make a failure loud at the earliest point it can be seen. Three biases decide most calls: - **Prefer the construct that refuses over the one that converts** — `===` over `==`, `??` over `||`, `Number(s)` over `parseInt(s)`, a thrown error over a silent `undefined`. - **The declared engine baseline decides what may be written**, not the ECMAScript edition a feature belongs to. - **Reach for the built-in globals first.** A dependency earns its place by doing what `Intl`, `URL`, `structuredClone`, `AbortController`, and the iterator helpers do not. ## Language Edition Read the project's engine baseline before writing code: `engines` in `package.json`, `browserslist`, `target` and `lib` in `tsconfig.json` or `jsconfig.json`, `.nvmrc`, and the CI matrix. Where a transpiler stands between source and runtime, its target governs the output and the source may run ahead; where none does, the engine baseline's oldest engine governs the source. **An edition number is not an availability claim.** Engines ship features years before ratification and lag on others, and the gap runs both ways inside a single edition: `Array.fromAsync` and `Math.sumPrecise` are both ES2026, yet the first shipped in Chrome 121 and reached Baseline widely available on 2026-07-25, while the second reached Bas