JavaScript

Intermediate · Roadmap · 39 lessons · 7 groups

The language itself — syntax, types, scope, functions, prototypes, classes, collections, the asynchronous model, modules, and the modern syntax and built-ins that make up idiomatic JavaScript — independent of any browser API or runtime. DOM manipulation, fetch, and browser storage are taught in `frontend`; the type system lives in `typescript`; Node's own runtime and module tooling live in `nodejs`. Thirty-nine lessons.

0%

Not started

Nothing saved yet. Progress is kept in this browser until you sign in.

Start the path

Language foundations · 7

Functions and `this` · 6

Objects, prototypes, and classes · 4

Collections and iteration · 5

Asynchronous JavaScript · 5

Modules and language utilities · 6

Advanced JavaScript · 6

01How JavaScript Code Is Parsed and ExecutedWhat happens between saving a .js file and a line of it running — parsing, bytecode, the JIT, and why "interpreted" undersells what engines like V8 do.Beginner · 11 min02Values, Types, and CoercionThe primitive types JavaScript has, what `typeof` really tells you, how implicit vs explicit coercion works, and truthy/falsy and `NaN` quirks.Beginner · 21 min03Equality and ComparisonHow `==` and `===` differ, what `Object.is` fixes that neither can, the SameValueZero algorithm `Map`/`Set` use, and why `==` surprises trace to coercion.Beginner · 12 min04Variables, Scope, and HoistingThe real differences between `var`, `let`, and `const`, function vs block scope, and why the temporal dead zone throws instead of returning `undefined`.Beginner · 10 min05Strict ModeWhat `'use strict'` changes, which silent failures it turns into thrown errors, and why ES modules and classes are already strict by default.Beginner · 6 min06Template Literals and Tagged TemplatesBacktick strings with `${}` interpolation and multi-line text, plus tagged templates — a function that intercepts a literal's pieces before they're joined.Beginner · 11 min07Optional Chaining, Nullish Coalescing, and Logical Assignment`?.` for safely reading a chain that might be `null`, `??` for defaulting only on missing values (not every falsy one), and the `||=`/`&&=`/`??=` operators.Beginner · 11 min01Function Declarations, Expressions, and Arrow FunctionsFunction declarations, expressions, and arrow functions do the same job, but differ in when they exist, hoisting, and what `this` means inside them.Beginner · 9 min02Default, Rest, and Spread ParametersDefault parameter values, rest parameters, and the spread syntax for unpacking an array into a function call — three small but common pieces of syntax.Beginner · 9 min03The `this` Keyword, `call`, `apply`, and `bind`Why `this` is decided at call time, not definition time, the binding rules behind it, and how `call`, `apply`, and `bind` override it on purpose.Intermediate · 34 min04ClosuresWhy an inner function keeps access to an outer function's variables after it returns — private state, memoization, and the loop-variable bug.Intermediate · 11 min05Common Closure Patterns: Debounce, Throttle, and MemoizationDebounce, throttle, memoization, and the "once" pattern — four utilities built the same way: a function closing over private state only it can see.Intermediate · 16 min06IIFEs and the Module PatternThe IIFE, and the pre-ES6 trick of pairing one with closures to fake private state and a public API — what people did before real modules existed.Intermediate · 14 min01Objects and Property DescriptorsWhat an object literal creates under the hood — the writable/enumerable/ configurable flags every property carries, getters/setters, and `Object.freeze`/`seal`.Intermediate · 13 min02Prototypal Inheritance and Object.createHow JS objects share behavior without classes — the prototype chain, `Object.create`, `__proto__` vs `.prototype`, and how property lookup walks the chain.Intermediate · 10 min03ES6 Classes and Inheritance`class` syntax as sugar over the prototype chain — `constructor`/ `extends`/`super`, and how method resolution works when a subclass and parent both define one.Intermediate · 16 min04Private Fields and Static MembersReal, enforced privacy in classes with `#` fields, static members that belong to the class itself rather than any instance, and why it took until 2022.Intermediate · 10 min01Arrays and Array MethodsWhich built-in array methods mutate in place versus return a new array, and when to reach for `map`/`filter`/`reduce` instead of a loop.Intermediate · 16 min02Destructuring and SpreadPulling values out of arrays and objects with destructuring — nested, renamed, defaulted — and building new ones with the spread operator.Intermediate · 13 min03Map, Set, and Weak CollectionsWhy `Map` and `Set` exist alongside objects and arrays, when they're the better tool, and how `WeakMap`/`WeakSet` avoid leaks with weak references.Intermediate · 11 min04Iterators and GeneratorsThe iterator protocol behind `for...of`, how `Symbol.iterator` and `next()` work, and how generators use `yield` to write lazy, even infinite, sequences.Advanced · 10 min05Typed Arrays and ArrayBuffer`ArrayBuffer` as raw binary memory, the typed array views that give its bytes a numeric shape, and `DataView` for reading mixed types at byte offsets.Advanced · 17 min01The Event Loop and the Call StackHow a single-threaded engine runs timers and other work without blocking — the call stack, the host environment, and why microtasks cut ahead of macrotasks.Intermediate · 13 min02Callbacks and Callback HellPassing a function to run later — why deeply nested callbacks become the "pyramid of doom," and the error-first convention built to cope with it.Intermediate · 24 min03PromisesThe `Promise` object standing in for a value that doesn't exist yet — its three states, chaining with `.then`/`.catch`/`.finally`, and ways to combine promises.Intermediate · 12 min04Async/Await`async`/`await` as sugar over promises that reads top to bottom, and the mistake of awaiting serially in a loop when the work could run concurrently.Intermediate · 12 min05Error Handling and Custom Errors`try`/`catch`/`finally`, subclassing `Error` for custom error types, and async failure modes: unhandled rejections and `await` slipping past `try`/`catch`.Intermediate · 9 min01ES Modules: Import and ExportHow `import`/`export` make a module's dependencies readable without running it, why exported bindings stay live, and how CommonJS's `require` differs.Intermediate · 17 min02Dynamic Import, Top-Level Await, and `import.meta`Loading a module on demand with `import()`, using `await` at a module's top level instead of only inside `async` functions, and what `import.meta` tells you.Intermediate · 12 min03Strings and UnicodeThe string methods you reach for daily, why strings are immutable, and the UTF-16 gotcha behind why `"😀".length` is `2`.Intermediate · 28 min04Regular ExpressionsPattern syntax for matching text — classes, quantifiers, and groups — plus the methods that run a pattern and the gotchas that catch almost everyone once.Intermediate · 17 min05JSON and SerializationTurning a value into a JSON string and back with `JSON.stringify`/`parse`, their `replacer`/`reviver` hooks, and what gets lost on the way through.Beginner · 15 min06Dates, Numbers, and Internationalization`Date`'s well-known rough edges, why `0.1 + 0.2 !== 0.3`, and using `Intl` to format dates and numbers correctly instead of hand-rolling it.Intermediate · 10 min01Symbols and Well-Known Symbols`Symbol` as a primitive that never collides, why that makes it a useful property key, and how "well-known" symbols hook into built-in behavior.Advanced · 12 min02Proxies and ReflectHow `Proxy` intercepts operations through traps like `get`/`set`/`has`/`deleteProperty`, how `Reflect` gives traps a safe fallback, and real uses.Advanced · 18 min03Functional Patterns in JavaScriptWriting JavaScript in a practical functional style — pure functions, immutability by convention, higher-order functions, currying, and composition.Intermediate · 10 min04Memory Management and Garbage CollectionHow a JS engine decides what memory to reclaim and when, mark-and-sweep, and the everyday leaks — forgotten timers, listeners, closures.Advanced · 27 min05`WeakRef` and `FinalizationRegistry`Holding a reference that doesn't stop garbage collection, running cleanup when an object is collected, and why both are last-resort, non- deterministic tools.Advanced · 26 min06`BigInt` and Arbitrary-Precision IntegersWhy `Number` loses precision past `MAX_SAFE_INTEGER`, the `BigInt` primitive and `123n` syntax, what can't mix with `Number`, and when it's overkill.Intermediate · 19 min

Language foundations

7 lessons

  1. 01 / 07How JavaScript Code Is Parsed and ExecutedWhat happens between saving a .js file and a line of it running — parsing, bytecode, the JIT, and why "interpreted" undersells what engines like V8 do.11 min
  2. 02 / 07Values, Types, and CoercionThe primitive types JavaScript has, what `typeof` really tells you, how implicit vs explicit coercion works, and truthy/falsy and `NaN` quirks.21 min
  3. 03 / 07Equality and ComparisonHow `==` and `===` differ, what `Object.is` fixes that neither can, the SameValueZero algorithm `Map`/`Set` use, and why `==` surprises trace to coercion.12 min
  4. 04 / 07Variables, Scope, and HoistingThe real differences between `var`, `let`, and `const`, function vs block scope, and why the temporal dead zone throws instead of returning `undefined`.10 min
  5. 05 / 07Strict ModeWhat `'use strict'` changes, which silent failures it turns into thrown errors, and why ES modules and classes are already strict by default.6 min
  6. 06 / 07Template Literals and Tagged TemplatesBacktick strings with `${}` interpolation and multi-line text, plus tagged templates — a function that intercepts a literal's pieces before they're joined.11 min
  7. 07 / 07Optional Chaining, Nullish Coalescing, and Logical Assignment`?.` for safely reading a chain that might be `null`, `??` for defaulting only on missing values (not every falsy one), and the `||=`/`&&=`/`??=` operators.11 min

Functions and `this`

6 lessons

  1. 01 / 06Function Declarations, Expressions, and Arrow FunctionsFunction declarations, expressions, and arrow functions do the same job, but differ in when they exist, hoisting, and what `this` means inside them.9 min
  2. 02 / 06Default, Rest, and Spread ParametersDefault parameter values, rest parameters, and the spread syntax for unpacking an array into a function call — three small but common pieces of syntax.9 min
  3. 03 / 06The `this` Keyword, `call`, `apply`, and `bind`Why `this` is decided at call time, not definition time, the binding rules behind it, and how `call`, `apply`, and `bind` override it on purpose.34 min
  4. 04 / 06ClosuresWhy an inner function keeps access to an outer function's variables after it returns — private state, memoization, and the loop-variable bug.11 min
  5. 05 / 06Common Closure Patterns: Debounce, Throttle, and MemoizationDebounce, throttle, memoization, and the "once" pattern — four utilities built the same way: a function closing over private state only it can see.16 min
  6. 06 / 06IIFEs and the Module PatternThe IIFE, and the pre-ES6 trick of pairing one with closures to fake private state and a public API — what people did before real modules existed.14 min

Objects, prototypes, and classes

4 lessons

  1. 01 / 04Objects and Property DescriptorsWhat an object literal creates under the hood — the writable/enumerable/ configurable flags every property carries, getters/setters, and `Object.freeze`/`seal`.13 min
  2. 02 / 04Prototypal Inheritance and Object.createHow JS objects share behavior without classes — the prototype chain, `Object.create`, `__proto__` vs `.prototype`, and how property lookup walks the chain.10 min
  3. 03 / 04ES6 Classes and Inheritance`class` syntax as sugar over the prototype chain — `constructor`/ `extends`/`super`, and how method resolution works when a subclass and parent both define one.16 min
  4. 04 / 04Private Fields and Static MembersReal, enforced privacy in classes with `#` fields, static members that belong to the class itself rather than any instance, and why it took until 2022.10 min

Collections and iteration

5 lessons

  1. 01 / 05Arrays and Array MethodsWhich built-in array methods mutate in place versus return a new array, and when to reach for `map`/`filter`/`reduce` instead of a loop.16 min
  2. 02 / 05Destructuring and SpreadPulling values out of arrays and objects with destructuring — nested, renamed, defaulted — and building new ones with the spread operator.13 min
  3. 03 / 05Map, Set, and Weak CollectionsWhy `Map` and `Set` exist alongside objects and arrays, when they're the better tool, and how `WeakMap`/`WeakSet` avoid leaks with weak references.11 min
  4. 04 / 05Iterators and GeneratorsThe iterator protocol behind `for...of`, how `Symbol.iterator` and `next()` work, and how generators use `yield` to write lazy, even infinite, sequences.10 min
  5. 05 / 05Typed Arrays and ArrayBuffer`ArrayBuffer` as raw binary memory, the typed array views that give its bytes a numeric shape, and `DataView` for reading mixed types at byte offsets.17 min

Asynchronous JavaScript

5 lessons

  1. 01 / 05The Event Loop and the Call StackHow a single-threaded engine runs timers and other work without blocking — the call stack, the host environment, and why microtasks cut ahead of macrotasks.13 min
  2. 02 / 05Callbacks and Callback HellPassing a function to run later — why deeply nested callbacks become the "pyramid of doom," and the error-first convention built to cope with it.24 min
  3. 03 / 05PromisesThe `Promise` object standing in for a value that doesn't exist yet — its three states, chaining with `.then`/`.catch`/`.finally`, and ways to combine promises.12 min
  4. 04 / 05Async/Await`async`/`await` as sugar over promises that reads top to bottom, and the mistake of awaiting serially in a loop when the work could run concurrently.12 min
  5. 05 / 05Error Handling and Custom Errors`try`/`catch`/`finally`, subclassing `Error` for custom error types, and async failure modes: unhandled rejections and `await` slipping past `try`/`catch`.9 min

Modules and language utilities

6 lessons

  1. 01 / 06ES Modules: Import and ExportHow `import`/`export` make a module's dependencies readable without running it, why exported bindings stay live, and how CommonJS's `require` differs.17 min
  2. 02 / 06Dynamic Import, Top-Level Await, and `import.meta`Loading a module on demand with `import()`, using `await` at a module's top level instead of only inside `async` functions, and what `import.meta` tells you.12 min
  3. 03 / 06Strings and UnicodeThe string methods you reach for daily, why strings are immutable, and the UTF-16 gotcha behind why `"😀".length` is `2`.28 min
  4. 04 / 06Regular ExpressionsPattern syntax for matching text — classes, quantifiers, and groups — plus the methods that run a pattern and the gotchas that catch almost everyone once.17 min
  5. 05 / 06JSON and SerializationTurning a value into a JSON string and back with `JSON.stringify`/`parse`, their `replacer`/`reviver` hooks, and what gets lost on the way through.15 min
  6. 06 / 06Dates, Numbers, and Internationalization`Date`'s well-known rough edges, why `0.1 + 0.2 !== 0.3`, and using `Intl` to format dates and numbers correctly instead of hand-rolling it.10 min

Advanced JavaScript

6 lessons

  1. 01 / 06Symbols and Well-Known Symbols`Symbol` as a primitive that never collides, why that makes it a useful property key, and how "well-known" symbols hook into built-in behavior.12 min
  2. 02 / 06Proxies and ReflectHow `Proxy` intercepts operations through traps like `get`/`set`/`has`/`deleteProperty`, how `Reflect` gives traps a safe fallback, and real uses.18 min
  3. 03 / 06Functional Patterns in JavaScriptWriting JavaScript in a practical functional style — pure functions, immutability by convention, higher-order functions, currying, and composition.10 min
  4. 04 / 06Memory Management and Garbage CollectionHow a JS engine decides what memory to reclaim and when, mark-and-sweep, and the everyday leaks — forgotten timers, listeners, closures.27 min
  5. 05 / 06`WeakRef` and `FinalizationRegistry`Holding a reference that doesn't stop garbage collection, running cleanup when an object is collected, and why both are last-resort, non- deterministic tools.26 min
  6. 06 / 06`BigInt` and Arbitrary-Precision IntegersWhy `Number` loses precision past `MAX_SAFE_INTEGER`, the `BigInt` primitive and `123n` syntax, what can't mix with `Number`, and when it's overkill.19 min
Esc
↑↓ navigate↵ open? shortcuts

Keyboard shortcuts

Press Esc to close

Anywhere

⌘K
Search and commands
/
Search
?
This sheet
Esc
Close

Reading a lesson

J
Next lesson
K
Previous lesson
B
Bookmark