javascript

Installation
SKILL.md

JavaScript

Modern JS is expressive and fast — most footguns come from async handling, mutation, and equality/coercion surprises. Prefer clarity and immutability; let the engine optimize.

Language baseline

  • const by default, let when reassigning, never var.
  • Use ===/!==; avoid == (coercion surprises). Know that NaN !== NaN (use Number.isNaN).
  • Prefer pure functions and immutable updates ({...obj}, [...arr], .map/.filter/.reduce) over in-place mutation of shared data.
  • Optional chaining ?. and nullish coalescing ?? (distinct from ||, which also catches 0/"").
  • Use modules (import/export); no global leakage. Keep imports at the top.
  • Prefer for...of / array methods over index loops; Map/Set over object-as-dict for dynamic keys.

Async done right

Installs
1
First Seen
Jul 5, 2026
javascript — shreyam1008/shre-skills