Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Writes, debugs, and refactors JavaScript code using modern ES2023+ features, async/await patterns, ESM module systems, and Node.js APIs. Use when building vanilla JavaScript applications, implementing Promise-based async flows, optimising browser or Node.js performance, working with Web Workers or Fetch API, or reviewing .js/.mjs/.cjs files for correctness and best practices.
.claude/skills/jeffallan-javascript-pro/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-04 | ✗→✓ | ▲ Improved | -5% | 0% |
| case-05 | ✗→✓ | ▲ Improved | 29% | 0% |
| case-09 | ✗→✓ | ▲ Improved | -3% | 0% |
| case-13 | ✗→✓ | ▲ Improved | 15% | 0% |
| case-14 | ✗→✓ | ▲ Improved | 23% | 0% |
package.json, module system, Node version, browser targets; confirm .js/.mjs/.cjs conventionseslint --fix); if linter fails, fix all reported issues and re-run before proceeding. Check for memory leaks with DevTools or --inspect, verify bundle size; if leaks are found, resolve them before continuingLoad detailed guidance based on context:
| Topic | Reference | Load When | |-------|-----------|-----------| | Modern Syntax | references/modern-syntax.md | ES2023+ features, optional chaining, private fields | | Async Patterns | references/async-patterns.md | Promises, async/await, error handling, event loop | | Modules | references/modules.md | ESM vs CJS, dynamic imports, package.json exports | | Browser APIs | references/browser-apis.md | Fetch, Web Workers, Storage, IntersectionObserver | | Node Essentials | references/node-essentials.md | fs/promises, streams, EventEmitter, worker threads |
X | null or X | undefined patterns?.) and nullish coalescing (??)import/export) for new projectsvar (always use const or let)js// ✅ Correct — always handle async errors explicitly async function fetchUser(id) { try { const response = await fetch(`/api/users/${id}`); if (!response.ok) throw new Error(`HTTP ${response.status}`); return await response.json(); } catch (err) { console.error("fetchUser failed:", err); return null; } } // ❌ Incorrect — unhandled rejection, no null guard async function fetchUser(id) { const response = await fetch(`/api/users/${id}`); return response.json(); }
js// ✅ Correct const city = user?.address?.city ?? "Unknown"; // ❌ Incorrect — throws if address is undefined const city = user.address.city || "Unknown";
js// ✅ Correct — named exports, no default-only exports for libraries // utils/math.mjs export const add = (a, b) => a + b; export const multiply = (a, b) => a * b; // consumer.mjs import { add } from "./utils/math.mjs"; // ❌ Incorrect — mixing require() with ESM const { add } = require("./utils/math.mjs");
js// ✅ Correct const MAX_RETRIES = 3; let attempts = 0; // ❌ Incorrect var MAX_RETRIES = 3; var attempts = 0;
When implementing JavaScript features, provide:
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-01 | pass→pass | 26,063 | 20,935 | -20% | 1 | 1 | 0% | 5,492 | 5,804 | +6% | 0 | 0 | — |
case-02 | fail→fail | 27,392 | 26,603 | -3% | 1 | 1 | 0% | 6,201 | 7,237 | +17% | 0 | 0 | — |
case-03 | fail→fail | 23,949 | 30,620 | +28% | 1 | 1 | 0% | 5,316 | 7,230 | +36% | 0 | 0 | — |
case-04 | fail→pass | 19,941 | 12,333 | -38% | 1 | 1 | 0% | 4,025 | 3,833 | -5% | 0 | 0 | — |
case-05 | fail→pass | 14,443 | 13,260 | -8% | 1 | 1 | 0% | 3,031 | 3,918 | +29% | 0 | 0 | — |
case-06 | pass→pass | 15,869 | 16,345 | +3% | 1 | 1 | 0% | 3,801 | 4,737 | +25% | 0 | 0 | — |
case-07 | pass→pass | 14,955 | 16,025 | +7% | 1 | 1 | 0% | 3,424 | 4,403 | +29% | 0 | 0 | — |
case-08 | pass→pass | 12,959 | 16,702 | +29% | 1 | 1 | 0% | 3,202 | 5,086 | +59% | 0 | 0 | — |
case-09 | fail→pass | 26,694 | 22,382 | -16% | 1 | 1 | 0% | 6,186 | 6,012 | -3% | 0 | 0 | — |
case-10 | pass→pass | 20,874 | 13,643 | -35% | 1 | 1 | 0% | 3,489 | 4,463 | +28% | 0 | 0 | — |
case-11 | pass→pass | 18,695 | 19,163 | +3% | 1 | 1 | 0% | 3,839 | 5,215 | +36% | 0 | 0 | — |
case-22 | pass→pass | 17,394 | 16,045 | -8% | 1 | 1 | 0% | 4,096 | 4,846 | +18% | 0 | 0 | — |
case-12 | pass→pass | 18,144 | 21,572 | +19% | 1 | 1 | 0% | 4,318 | 5,924 | +37% | 0 | 0 | — |
case-13 | fail→pass | 19,683 | 17,277 | -12% | 1 | 1 | 0% | 4,419 | 5,078 | +15% | 0 | 0 | — |
case-14 | fail→pass | 24,871 | 27,496 | +11% | 1 | 1 | 0% | 5,885 | 7,220 | +23% | 0 | 0 | — |
case-15 | pass→pass | 20,339 | 18,690 | -8% | 1 | 1 | 0% | 3,944 | 5,437 | +38% | 0 | 0 | — |
case-16 | fail→fail | 18,966 | 19,797 | +4% | 1 | 1 | 0% | 3,880 | 5,242 | +35% | 0 | 0 | — |
case-17 | fail→pass | 26,416 | 23,690 | -10% | 1 | 1 | 0% | 5,630 | 6,328 | +12% | 0 | 0 | — |
case-18 | pass→pass | 14,350 | 18,934 | +32% | 1 | 1 | 0% | 2,882 | 4,884 | +69% | 0 | 0 | — |
case-19 | fail→fail | 17,645 | 20,367 | +15% | 1 | 1 | 0% | 4,013 | 4,792 | +19% | 0 | 0 | — |
case-20 | pass→pass | 5,204 | 8,630 | +66% | 1 | 1 | 0% | 1,110 | 2,480 | +123% | 0 | 0 | — |
case-21 | pass→pass | 7,562 | 13,134 | +74% | 1 | 1 | 0% | 1,612 | 4,210 | +161% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted. The headline lift of +27 percentage points is the difference between those two pass rates over the 22 comparable cases. 1 case got worse with the skill loaded, and it is included in that figure.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.