September 2024
Storybook 8.3 is out
A new release for Storybook with better vitest implementation to run your stories as tests, new Nextjs plugin, and different size & performance improvements.
A new release for Storybook with better vitest implementation to run your stories as tests, new Nextjs plugin, and different size & performance improvements.
And what if we were doing our tests directly in storybook ? What if just by using storybook we could write less tests. And what if visual testing with snapshots were the answer ? Storybook give us its point of view on theses questions in this article.
Great introduction on how to install and use Playwright to your E2E tests. Artem explain all the setup, the use of Mock Service Workers to mock api calls, but also guide you through the building of your different tests.
Playwright can take existing stories from storybook and directly test scenarios from them. It allows to share configuration between the tools. That's why storybook launched an experimental features named Portable stories.
A goldmine for understanding and optimizing our component tests. A must-read.
Because we haven't talked about tests yet today, here's a tutorial on setting up and using Vitest to test custom hooks.
Netflix presents a new testing library, which has the particularity of sharing component and E2E tests. The promise seems quite appealing.