Skip to content
Testing Forms, Interaction, and State — with user-event thumbnail

Testing Forms, Interaction, and State — with user-event

This is Part 8 of the “Frontend Testing, Done Right” series. Browse the full series · Glossary A button isn’t really tested until you press it; an input, until you type into it. user-event is the member of the Testing Library family in charge of reproducing interaction — even a single click walks through focus changes and key-event order just like a real browser, closing the gap where “it works when a user does it, but not in the test.” In this article we build typing and clicking tests from scratch. ...

Published date: 2026-07-13 · Reading time: 6 min · Word count: 2745 words · Author: Isaac
The Testing Library Philosophy — Querying Like a User thumbnail

The Testing Library Philosophy — Querying Like a User

This is Part 7 of the “Frontend Testing, Done Right” series. Browse the full series · Glossary Testing Library is the de facto standard for component testing in React and beyond. But the real substance of this tool isn’t its API — it’s one philosophy. The moment you start testing components, temptations appear: “should I find it by class name? peek at internal state?” Testing Library answers firmly: do what the user does. In this article we’ll see what that philosophy means, the order for choosing queries, and why this approach is inseparable from accessibility — all while building a search component from scratch. ...

Published date: 2026-07-10 · Reading time: 7 min · Word count: 3154 words · Author: Isaac
Wiring Vitest into the Demo App — All the Way to the First Green Light thumbnail

Wiring Vitest into the Demo App — All the Way to the First Green Light

This is Part 3 of the “Frontend Testing, Done Right” series. Browse the full series · Glossary This is a start-to-finish walkthrough of wiring a testing environment into a React + Vite + TypeScript project — from an empty folder to the first passing test. We install Vitest, Testing Library, and jsdom, read the config line by line, turn the first test green, and map out where setup most often goes wrong. One article, complete setup. ...

맨 위로