JavaScript typing practice

Real JavaScript, typed exactly as written. Arrow functions and nested braces are the two patterns that slow most developers down.

0wpm
100% acc
0:00Time
const active = users .filter((user) => user.status === "active") .map((user) => ({ id: user.id, name: user.name })) .sort((a, b) => a.name.localeCompare(b.name));

Just start typing.Tabrestarts

Left handRight hand

Snippet: Array pipeline (javascript)

The JavaScript symbol profile

JavaScript leans hard on a handful of characters that barely appear in prose: parentheses, braces, the arrow made of hyphen and greater-than, backticks and the dollar-brace of template literals.

Arrow functions are the specific pattern worth drilling. The sequence of close-paren, space, hyphen, greater-than, space, open-brace involves four different fingers and two shift presses, and it appears constantly.

What to watch for

Transposed brackets - typing the closing character before the opening one - are the most common JavaScript typing error, and they are usually a rhythm problem rather than a knowledge problem.

The backtick is worth specific attention. It sits at the far top-left under the left little finger, is almost never used in prose, and appears in every template literal.

Common questions

Do I type the semicolons?

Type the snippet exactly as shown. The snippets here use semicolons, so yes - and the semicolon is a right-little-finger key that is worth the practice regardless of your style preference.

Keep going