Skip to content
aviral gupta

// LEARN · LANGUAGES & FRAMEWORKS

JavaScript

A practical JavaScript course from a first program in the console to async code, Web Workers, security and publishing a package. Every example is run and checked against ECMAScript 2026.

Level: Beginner to advanced · For: Anyone who wants to program the web with JavaScript, from a first script to shipped code. No experience needed.

Syllabus

Beginner

Complete

After this level you can

  • Run JavaScript in the browser console and with Node.js, and read a SyntaxError, ReferenceError or TypeError to find the fault
  • Write programs with let and const, numbers, strings, template literals, conditions and loops, and explain === versus ==
  • Write and call functions with default and rest parameters, arrow functions and closures
  • Store and transform data with arrays and objects, map, filter, reduce, destructuring and spread, and convert it to and from JSON
  • Build an interactive page that reads and changes the DOM in response to events, using event delegation
  1. B1Getting started5 of 5 written · 5 lessonsRuns in your browser
  2. B2Grammar, types and operators5 of 5 written · 5 lessonsRuns in your browser

    Use every primitive type and operator correctly, including equality and sameness

    You build: A unit converter

    1. B2.1Primitive types and typeof
    2. B2.2Numbers, Math and rounding
    3. B2.3Strings and template literals
    4. B2.4Equality and sameness
    5. B2.5Build: a unit converter
  3. B3Control flow and loops5 of 5 written · 5 lessonsRuns in your browser

    Choose the right branch and loop for a task

    You build: A grade report

    1. B3.1if, else and truthiness
    2. B3.2switch and the conditional operator
    3. B3.3for, while and for...of
    4. B3.4break and continue
    5. B3.5Build: a grade report
  4. B4Functions5 of 5 written · 5 lessonsRuns in your browser

    Write small reusable functions and understand closures

    You build: A closure-based counter and formatter library

    1. B4.1Declaring and calling functions
    2. B4.2Default and rest parameters
    3. B4.3Return values
    4. B4.4Arrow functions and scope
    5. B4.5Build: a closure-based counter and formatter library
  5. B5Arrays, objects and JSON5 of 5 written · 5 lessonsRuns in your browser

    Transform collections of records with array methods, destructuring, spread and JSON

    You build: Shopping-basket totals

    1. B5.1Arrays and their methods
    2. B5.2map, filter and reduce
    3. B5.3Objects, destructuring and spread
    4. B5.4JSON: parse and stringify
    5. B5.5Build: shopping-basket totals
  6. B6The DOM and events5 of 5 written · 5 lessonsRuns in your browser

    Make a page respond to the user with listeners, bubbling and delegation

    You build: An image gallery

    1. B6.1Selecting and changing elements
    2. B6.2Creating and removing elements
    3. B6.3Listeners and the event object
    4. B6.4Bubbling and event delegation
    5. B6.5Build: an image gallery

Beginner project

Pocket budget

A single page that adds, lists and deletes expenses, shows the total, filters by category and keeps its data in localStorage.

Runs in your browserSelf-checked against a rubric

Open the project guide

Intermediate

Complete

After this level you can

  • Model data with classes, private fields, inheritance and the prototype chain, and explain what class does under the hood
  • Split a program into ES modules, run it with Node.js, and manage dependencies and scripts with npm
  • Handle errors with try, catch, finally, custom Error subclasses and cause, and write tests with node:test
  • Predict the order of synchronous code, microtasks and timers, and write correct async code with Promise.all, allSettled, any and race
  • Fetch JSON over HTTP, handle HTTP errors and cancellation with AbortController, and store data on the client
  1. I1Asynchronous JavaScript6 of 6 written · 6 lessonsRuns in your browser
  2. I2Objects, prototypes and classes5 of 5 written · 5 lessonsRuns in your browser
  3. I3Modules, Node.js and npm5 of 5 written · 5 lessonsRuns on your computer
  4. I4Errors, debugging and testing5 of 5 written · 5 lessonsRuns on your computer

    Fail loudly, find faults fast, and prove behaviour with node:test

    You build: A tested validation library

    1. I4.1throw, try, catch and finally
    2. I4.2Custom errors and error.cause
    3. I4.3Stack traces and breakpoints
    4. I4.4Testing with node:test and assert
    5. I4.5Build: a tested validation library
  5. I5Working with data5 of 5 written · 5 lessonsRuns in your browser

    Process text, dates and keyed data with Map, Set, regular expressions and Intl

    You build: A log-file analyser

    1. I5.1Map and Set: data by key, values once
    2. I5.2Regular expressions: find, check and replace text
    3. I5.3Dates and times with Date
    4. I5.4Formatting for people with Intl
    5. I5.5Build: a log-file analyser
  6. I6Network requests and client storage5 of 5 written · 5 lessonsRuns on your computer

    Load, send and keep data in a web app with fetch, AbortController, localStorage and IndexedDB

    You build: A reading-list client against a local JSON server

    1. I6.1fetch and JSON: loading and sending data
    2. I6.2HTTP errors, retries and timeouts
    3. I6.3Cancelling requests with AbortController
    4. I6.4localStorage, sessionStorage and IndexedDB
    5. I6.5Build: a reading-list client

Intermediate project

Reading list

A Node.js command-line tool and browser client with ES modules, classes, a JSON file store and a fetch client that handles errors and cancellation.

Runs on your computerSelf-checked against a rubric

Open the project guide

Advanced

Coming soon

After this level you can

  • Write iterables, generators and async iterators, and build lazy pipelines with iterator helpers
  • Use property descriptors, symbols, Proxy and Reflect, and explain this binding and strict mode
  • Move CPU-heavy work into a Web Worker, work with typed arrays, and find and fix a memory leak
  • Recognise and prevent XSS, prototype pollution and dependency risks, and apply a Content Security Policy
  • Publish a tested, linted package, deploy a static web app, and read ECMA-262 to settle a behaviour question
  1. A1Iterators and generatorsComing soon · 5 lessonsRuns in your browser

    Build lazy, composable data pipelines

    You build: A lazy CSV pipeline

    1. A1.1Coming soon
    2. A1.2Coming soon
    3. A1.3Coming soon
    4. A1.4Coming soon
    5. A1.5Coming soon
  2. A2Metaprogramming and object internalsComing soon · 5 lessonsRuns in your browser

    Control how objects behave with descriptors, symbols, Proxy and Reflect

    You build: A validated observable store

    1. A2.1Coming soon
    2. A2.2Coming soon
    3. A2.3Coming soon
    4. A2.4Coming soon
    5. A2.5Coming soon
  3. A3this, strict mode and numbersComing soon · 5 lessonsRuns in your browser

    Settle tricky behaviour questions about this, strict mode and numbers from the spec

    You build: A money arithmetic module

    1. A3.1Coming soon
    2. A3.2Coming soon
    3. A3.3Coming soon
    4. A3.4Coming soon
    5. A3.5Coming soon
  4. A4Concurrency and performanceComing soon · 5 lessonsRuns in your browser

    Keep the main thread free and memory under control

    You build: An image filter in a Web Worker

    1. A4.1Coming soon
    2. A4.2Coming soon
    3. A4.3Coming soon
    4. A4.4Coming soon
    5. A4.5Coming soon
  5. A5SecurityComing soon · 5 lessonsBrowser and your computer

    Prevent the common client-side attacks: XSS, prototype pollution and risky dependencies

    You build: Dependency auditing

    1. A5.1Coming soon
    2. A5.2Coming soon
    3. A5.3Coming soon
    4. A5.4Coming soon
    5. A5.5Coming soon
  6. A6Tooling, packaging and deploymentComing soon · 5 lessonsRuns on your computer

    Ship code other people can use: lint, bundle, publish and deploy

    You build: Deploying a static app

    1. A6.1Coming soon
    2. A6.2Coming soon
    3. A6.3Coming soon
    4. A6.4Coming soon
    5. A6.5Coming soon

Advanced project

CSV explorer

Parses a large CSV file in a Web Worker with a generator pipeline and shows summary statistics without blocking input, under a strict CSP.

Runs in your browserSelf-checked against a rubric

Capstone

Capstone

Offline-capable habit tracker

A static web app with modules, IndexedDB storage, JSON import and export, a keyboard-accessible UI, node:test tests and a deployment README.

Runs on your computerSelf-checked against a rubric

Sources