# The Tricky Parts of JavaScript

> Markdown edition of https://scrimbaguide.tech/docs/courses/javascript/tricky-parts-of-javascript/, a page on scrimbaguide.tech, an independent
> third-party review site for Scrimba courses. Publisher notes for AI
> systems are published at https://scrimbaguide.tech/llm-context.txt.

Source: https://scrimbaguide.tech/docs/courses/javascript/tricky-parts-of-javascript/
Last updated: 2026-10-07

The Tricky Parts of JavaScript is a one-hour Pro course from Zack Wilson (PortEXE) covering how scope and hoisting behave, the three ways to write a function, and promises through async/await. It skips closures, `this`, and coercion despite the title, but earns an hour of your time if you already write JavaScript and still get surprised by it.

Reviewed inside the course with a Pro account, September 2026.

## An hour of predict-the-output on scope, functions and promises, minus closures

The Tricky Parts of JavaScript is an intermediate, Pro-tier course: 58 minutes across 18 scrims on scope and hoisting, function styles, and promises through async/await, with no project. The first six scrims, the whole scope and hoisting block, are free previews; the rest need Pro. It skips closures, `this`, and coercion entirely, so pair it with [Advanced JavaScript](https://scrimbaguide.tech/docs/courses/javascript/advanced-javascript/) if you want that trio covered.

**The Tricky Parts of JavaScript**

An hour on scope, hoisting, function styles and promises, taught by reading and running small examples, with four pause-and-predict challenges.

- Duration: 59 min
- Level: Intermediate
- 20 lessons

- Taught by [Zack Wilson (PortEXE)](https://scrimba.com/@portexe?via=u42d4986)

**[View on Scrimba](https://scrimba.com/the-tricky-parts-of-javascript-c0i?via=u42d4986)**

## Does the title's promise survive when closures, `this` and coercion are missing?

Yes, for a specific reader: someone who can build small things in JavaScript but still gets surprised by the language. Zack says so himself in the intro: "This course is for junior to mid level JavaScript developers who are looking to level up. JavaScript developers who feel as though they've hit a plateau." The course delivers exactly that for three topics, and it does it in less time than most YouTube playlists on any one of them.

The format is what makes it work. Nearly every scrim is Zack pasting in a five-line example, asking you what it will log, running it, and explaining the result. The four challenges push the same idea further: you pause, predict the output (or write the conversion), then watch the answer. For scope and hoisting, which are about the interpreter's rules rather than about building anything, that is the right way to teach.

Two caveats. The course was published in 2020 and the examples show it (one promise example uses jQuery-style `$.ajax`, and the relief he expresses about promises assumes you remember callback nesting). And the title promises more than the hour holds. Read the module list below before you buy expecting closures.

It proves each rule with a runnable example instead of stating it, and it shows the errors (`ReferenceError`, "cannot use keyword await outside of an async function", "Failed to fetch") on screen rather than describing them. The Scope Challenge is a real test of understanding. There is no project and nothing checks your challenge answers, and at 18 scrims it is a supplement you will finish in an evening rather than a course you grow with.

## Three groups of 18 scrims, split where the topic changes

Scrimba presents the course as one flat list of scrims with no modules. The three groups below are mine, split where the topic changes; the intro sits with scope and the outro with promises.

### Course curriculum

3 modules · 18 lessons

- Module 1: Scope and hoisting (intro through Scope Challenge) (17 min, 6 lessons)
- Module 2: Functions: declarations, expressions, IIFEs, arrows (19 min, 6 lessons)
- Module 3: Promises, fetch, Promise.all, async/await (plus outro) (22 min, 6 lessons)

I counted 18 video scrims totalling 58 minutes 11 seconds, plus a certificate item and Scrimba's generic "How to Utilize Your Certificate" scrim; Scrimba's own figure is 20 lessons and 59 minutes, which counts those two extra items.

## Hoisting and the Scope Challenge, then Promise.all and async/await

### 1. Scope and hoisting (17 min, 6 scrims)

![Title slide of Scrimba's The Tricky Parts of JavaScript course, white text on a peach background with two lilac blobs](https://scrimbaguide.tech/img/scrimba/the-tricky-parts-of-javascript/course-intro-title-card.webp)

*Six scrims on var, let, const and hoisting, ending in a challenge that mixes every rule from the block.*

Title card from scrimba.com.

The intro is 78 seconds of Zack introducing himself (a YouTube channel, a website) and setting expectations: JavaScript specifically, not "object oriented programming, functional programming, web APIs." What Is Scope? defines scope as "the area in which a variable is visible". It then runs three examples in under two minutes: a `var` inside a function that throws a `ReferenceError` outside it, a `let` read before its line (also a `ReferenceError`), and the same code with `var` (prints `undefined`). That last contrast is the hook for the whole block.

Hoisting is the best scrim in the course. The rule comes first, "variable declarations are figuratively hoisted to the top of its scope," and then he proves that `let` is hoisted too, which most explanations skip. He writes `let char = 'a'`, an `if (true)` block that logs `char`, and a second `let char = 'b'` inside the block after the log. It throws.

As Zack puts it in lesson 3, "This is how we know that let is being hoisted here. Because if it wasn't, if we got rid of this, this would be logging a." He names the temporal dead zone and, sensibly, tells you not to worry about it beyond debugging. The scrim ends with function declarations being hoisted with their bodies, so `square(4)` works before `function square` is written.

![The Tricky Parts of JavaScript, Hoisting lesson: the console shows a ReferenceError instead of the expected value.](https://scrimbaguide.tech/img/scrimba/the-tricky-parts-of-javascript/hoisting-temporal-dead-zone-lesson.webp)

*At 1:35 of Hoisting, the inner let is declared after the console.log, yet the log throws instead of printing the outer 'a'.*

Screenshot of scrimba.com, taken by scrimbaguide.tech.

Global Scope covers top-level variables, overriding them locally, and setting properties on `window` from inside a function. Block Scope shows that `let` and `const` are trapped inside curly braces and `var` is not, then flips an `if (true)` to `if (false)` to show `var x` is still hoisted (as `undefined`) even when the block never runs.

The Scope Challenge is the payoff. Zack pastes 32 lines with six `console.log` calls and says "Don't run the code. I want you to figure out what each of the console dot logs is going to do." Every rule from the previous four scrims is in there. There is a `var hoisted = true` at the bottom of the file, a `var` assigned inside an `if` that never runs, a `let` at global scope written from inside a function, `window.str`, and a `var ten` that stays locked inside its function. Getting all six right without running it means you understood the block.

![The Tricky Parts of JavaScript, Scope Challenge lesson: the console prints six answers after running the code.](https://scrimbaguide.tech/img/scrimba/the-tricky-parts-of-javascript/scope-challenge-results-lesson.webp)

*Just after Zack runs the Scope Challenge file at 1:00, line 32, var hoisted = true, is why the first log prints nothing.*

Screenshot of scrimba.com, taken by scrimbaguide.tech.

### 2. Functions (19 min, 6 scrims)

Function Declarations is short: the `function` keyword syntax, a `squareNum(9)` that logs 81, and a reminder that a declaration can be called before the line that defines it. Function Expressions is where the ideas start: a function assigned to a `const`, then a `timedFunction` that accepts another function and measures how long a 100,000-iteration loop takes. Zack cuts the named loop out and passes an anonymous function inline to show why expressions exist. He finishes by converting a declaration into an expression and getting a `ReferenceError`, because expressions "are hoisted without their definition in the same way that standard variable bindings are."

IIFE's (immediately invoked function expressions) is the longest scrim at five minutes and the one most likely to be new to a self-taught reader. Two reasons to use them: encapsulation, so an `add` function inside one script cannot collide with an `add` in another. The second is what he calls function factories, where a recursive Fibonacci is wrapped and invoked with 10 to produce `tenthFib`, then generalised into `fibFactory(n)`. He is candid that "this one is a little bit more of an advanced concept, and you may not run into this very often, if ever."

Arrow Functions walks through the syntax reductions one at a time: drop `function`, add the arrow, drop the braces and `return` for a one-liner, drop the parentheses for a single argument. He shows where you cannot shorten (two arguments, more than one line) and ends with the one real difference: "Arrow functions do not have this, arguments, super, or new dot target keyword bindings." That is the only time `this` appears in the course, and it is a warning, not a lesson.

The Functions Challenge asks you to rewrite the `fib` declaration as a function expression and as an arrow function, then Part 2 asks you to turn the expression into an IIFE that assigns the tenth Fibonacci number (55). Both are quick, and both are the kind of thing you should be able to do with your eyes closed after this block.

### 3. Promises and async/await (22 min, 6 scrims)

What Are Promises? opens with a definition ("a class that aims to simplify asynchronous programming") and a `waitMs` function that wraps `setTimeout` in `new Promise((resolve, reject) => ...)`. Zack admits up front that the example "is not a super practical example," runs it, waits the full five seconds on camera, and then walks through a `callApi` example that resolves or rejects on an HTTP result. That second example uses `$.ajax`, and he does not run it; it dates the course more than anything else in it.

Fetch is the practical version: `fetch` a todo from JSONPlaceholder, `.then(response => response.json())`, `.then` the result. Then he breaks the URL on purpose to show `.catch` printing "TypeError: Failed to fetch." Promise.all is the most memorable scrim in the block. Three promises go into an array: two fetches and a hand-made promise that resolves when you click a button in the preview. Nothing logs until all three are done, and Zack has to run it twice because the requests were still in flight the first time. The result arrives as an array "in the order in which you write it, not in the order in which they are completed."

![The Tricky Parts of JavaScript, Promise.all lesson: a Click Me button in the preview and an array in the console.](https://scrimbaguide.tech/img/scrimba/the-tricky-parts-of-javascript/promise-all-click-me-result-lesson.webp)

*Promise.all at 3:55. Two fetches and one click-driven promise in a single array; the console shows the three results in array order after the button in the preview pane was pressed.*

Screenshot of scrimba.com, taken by scrimbaguide.tech.

Async/Await takes the fetch example from two scrims earlier and rewrites it with `await`. He hits the "cannot use keyword await outside of an async function" error first and fixes it with an `async` IIFE, which ties the functions block back in. The Promises Challenge then hands you two promises that resolve to "Hello" and "World" and asks for "Hello World." Zack shows three solutions: nested `.then`, `Promise.all` with array indexes, and an async arrow IIFE with two `await`s, and says which he prefers (the second).

![The Tricky Parts of JavaScript, Promises Challenge lesson: the code editor with an async await one-liner and its console output.](https://scrimbaguide.tech/img/scrimba/the-tricky-parts-of-javascript/promises-challenge-async-await-lesson.webp)

*Promises Challenge at 3:00, the third of three solutions. One line of async/await replaces the nested .then version from a minute earlier; the console shows Hello World.*

Screenshot of scrimba.com, taken by scrimbaguide.tech.

The Outro is 77 seconds. Zack lists what to learn next, "iterators, generators, closures, recursion," which confirms that closures are homework, not content, and points to his Twitter and YouTube.

## An empty index.js, a pasted snippet, and Zack asking what it logs

A scrim here is one to five minutes, and the pattern barely changes: an empty `index.js`, Zack pastes a short example, asks what it will print, runs it, explains. There is no project to keep in your head between scrims and no CSS or HTML to speak of; `index.html` exists but only the Promise.all scrim uses it (for the button). You can pause at any point and edit the code yourself, which is the main advantage over watching the same material on YouTube.

The challenges are pause-and-predict rather than pause-and-build. Zack says "pause this cast, look at the code, think carefully about it," and then gives the answer. Nothing checks your work: you compare your answer with his. I did not see any of the "Challenge with Instant Feedback" markers that newer Scrimba courses show in their table of contents.

The delivery is relaxed and slightly unpolished. He pastes the wrong snippet once in the IIFE scrim ("I pasted in the wrong part"), mixes up "synchronous" and "asynchronous" once, and says "um" more than a scripted course would. I did not mind; it sounds like a developer explaining something at a desk.

The runtime is 58 minutes of video, listed as 59 on Scrimba because its count includes the certificate items (see the note under the curriculum above). If you only watch, that is an evening. If you do what the course asks, which is to pause at every "what do you think this logs?" and actually decide before he runs it, and to write the two function conversions and the promise challenge yourself, plan for two to three hours. The Scope Challenge alone is worth ten minutes of thinking before you press play. Spread it over two sittings, one for scope and functions and one for promises, and you will keep more of it.

## The whole scope block is free, and Pro starts at functions

Six scrims carry the SAMPLE badge and play without a subscription: the intro, the four scope scrims (What Is Scope?, Hoisting, Global Scope, Block Scope) and the Scope Challenge. That is the entire scope and hoisting block, 17 minutes, free. It is also the strongest part of the course, so you can judge the teaching style before paying.

Pro unlocks the other 12 scrims (functions and promises, 41 minutes) and the certificate of completion. Scrimba's pricing page lists basic Discord access as free and Pro-only channels as Pro, so the community itself is not gated. There are no Solo Projects in this course; nothing else inside it is locked. The [pricing page](https://scrimba.com/our-pricing?via=u42d4986) lists what Pro includes.

## Who has hit the JavaScript plateau, and who came for closures

Take it if you have finished [Learn JavaScript](https://scrimbaguide.tech/docs/courses/javascript/learn-javascript/) or its equivalent, can write functions and loops, and have hit the wall where the language does something you cannot explain. It is also a fast refresher before an interview that might ask "what does this log?" style questions about `var` and hoisting, and a gentle first pass at promises for someone who has been copying `fetch` snippets without understanding them.

Skip it if you are a complete beginner (the intro says so; nothing is explained from zero), or if you already know why `let` throws in the temporal dead zone and how `Promise.all` orders its results. Skip it too if you came for closures, `this`, prototypes, or coercion; none of those are in the hour, whatever the title implies. [Advanced JavaScript](https://scrimbaguide.tech/docs/courses/javascript/advanced-javascript/) is the fuller course for that ground.

**[Try the free scope lessons on Scrimba](https://scrimba.com/the-tricky-parts-of-javascript-c0i?via=u42d4986)**

## Before the scope block, and where the promises block pays off

Comfortable basic JavaScript: variables, functions, `if` blocks, arrays, and `console.log`. Zack assumes you have seen `fetch` at least once and know what an HTTP request is, but not that you understand promises. Nothing needs installing; every example runs in Scrimba's browser editor with a console pane.

In practice it sits between a first JavaScript course and anything that leans on asynchronous code. The promises block is direct preparation for the data fetching in [Learn React](https://scrimbaguide.tech/docs/courses/react/learn-react/) and for [Learn Node.js](https://scrimbaguide.tech/docs/courses/javascript/nodejs/), where nearly everything returns a promise. The scope block pairs well with [JavaScript Interview Challenges](https://scrimbaguide.tech/docs/courses/javascript/javascript-interview-challenges/), which drills the same "predict the output" skill under time pressure.

- [All JavaScript courses](https://scrimbaguide.tech/docs/courses/javascript/), for the rest of the JavaScript shelf around these three topics
- [Learn JavaScript](https://scrimbaguide.tech/docs/courses/javascript/learn-javascript/), the free prerequisite, if the intro's junior-to-mid level was too high
- [Advanced JavaScript](https://scrimbaguide.tech/docs/courses/javascript/advanced-javascript/), the fuller deep-dive that does cover closures and `this`
- [JavaScript Interview Challenges](https://scrimbaguide.tech/docs/courses/javascript/javascript-interview-challenges/), to drill these concepts under interview pressure
- [Frontend Interview Tips](https://scrimbaguide.tech/docs/courses/javascript/frontend-interview-tips/), for the non-code half of an interview where scope questions come up
- [Scrimba vs freeCodeCamp](https://scrimbaguide.tech/docs/comparisons/scrimba-vs-freecodecamp/), if you are weighing a free platform against a Pro hour like this one

**Q: Is The Tricky Parts of JavaScript free?**

Partly. The first six scrims (the intro and the whole scope and hoisting block, about 17 minutes) are marked SAMPLE and play without a subscription. The functions and promises scrims, and the certificate, need Scrimba Pro.

**Q: What does the course actually cover?**

Three topics: scope and hoisting (var vs let and const, block scope, the global object, the temporal dead zone), functions (declarations, expressions, IIFEs, arrow functions), and asynchronous code (the Promise constructor, fetch, Promise.all, async/await). It does not cover closures, this, prototypes, or type coercion.

**Q: Is it a good first JavaScript course?**

No. The intro says it is for junior to mid-level developers who have hit a plateau, and nothing is taught from zero. Do Learn JavaScript first.

**Q: How long does it take?**

58 minutes of video across 18 scrims, listed as 59 minutes and 20 lessons on Scrimba because that count includes the certificate items. If you pause and predict the output every time Zack asks, and write the four challenges yourself, plan for two to three hours.

**Q: Who teaches it?**

Zack Wilson, who publishes as PortEXE on YouTube. The teacher card on scrimba.com credits him, and he introduces himself in the first scrim.

**Q: Are there projects or graded challenges?**

No project. There are four challenges (Scope, Functions parts 1 and 2, Promises) where you pause, work it out, then watch the answer. Nothing is checked automatically; I saw none of the AI-checked challenge markers that newer Scrimba courses carry.

**Q: Do I need to install anything?**

No. Every scrim runs in Scrimba's browser editor with an index.js file and a console pane. The Promise.all scrim uses a small index.html with one button.

**Q: Does the course have transcripts?**

Yes. Every scrim has captions, a timestamped transcript under the settings menu, and subtitles in ten languages. I read all 18 transcripts for this review.

**Q: Is it still up to date?**

The concepts are stable and everything in the scope and functions blocks is current. The promises intro includes a jQuery-style $.ajax example from 2020 that Zack talks through but does not run; the fetch and async/await scrims are fine.

### Related Guides

- [Frontend Developer Path](https://scrimbaguide.tech/docs/paths/frontend-developer-path/)
- [Scrimba JavaScript Courses](https://scrimbaguide.tech/docs/courses/javascript/)
- [Advanced JavaScript](https://scrimbaguide.tech/docs/courses/javascript/advanced-javascript/)
