Recent blog posts
React Server Components
Cheat sheets/mega posts
Vitest specific
Blog Posts & Resources
Testing async React RSC components
React RSC components have been out for a few years, but testing them in Vitest or Jest is still difficult. In this blog post I go over some approaches, work arounds and hacky fixes so you can test the async behaviour (and Suspense)
How to add type check assertions in Vitest
Did you know you can use Vitest to easily make assertions on your TypeScript types? In this page I will go over how you can easily start using this cool feature
Absolutely everything you need to know about act() in React tests
An in depth look into the act() function when testing React, how to use it, when to use it and fix common issues when using it
Frontend Testing Glossary
A glossary for all the confusing testing related words that get thrown around!
Jest Cheatsheet
Cheatsheet for common Jest testing tasks. Includes basic test structure, common matchers, handling async code, testing errors, and more. Hopefully you can find what you need here to copy and paste into your test code.
Welcome to the new HowToTestFrontend blog!
Welcome to the new HowToTestFrontend.com site, where you can learn how to test your Frontend applications.