AriPerkkio

AriPerkkio

@ariperkkio.dev

@vitest.dev Core Team • Open Source @chromatic.com • github.com/AriPerkkio

1.2K followers200 following119 posts

Latest work on Vitest's istanbuljs fork removed Babel from coverage-istanbul. Instrumentation is now done with packages that Vitest dep graphs already have: magic-string and rolldown, similar to Vite's own SSR transform. Surprisingly this dep trim improved instrumentation speed 5-10x.

github.comRelease v2.0.0 · vitest-dev/istanbuljs🚨 Breaking Changes lib-instrument: Replace babel with rolldown + magic-string  -  by @AriPerkkio in #28 (fdd34) @vitest/istanbul-lib-instrument no longer uses Babel. Code is parsed with OXC (v...

This Thursday we'll be discussing about Visual Regression Testing using @vitest.dev and @chromatic.com. Join me and @kylegach.com to hear how you can get VRT that's stable across your whole team, not just on your local machine. 📸

Chromatic@chromatic.com

@vitest.dev already renders your components in a real browser. Now you can visually test them there, with no test code changes. 🎙️ @ariperkkio.dev, the Vitest core maintainer who built our new plugin, is doing a live walkthru with @kylegach.com to show you how. 🎟️ Save your spot 👇

AriPerkkio reposted

Chromatic for @vitest.dev Browser Mode is live. 🧪📸 Browser Mode runs your component tests in a real browser. Now Chromatic checks how those components look by capturing the rendered UI. No new screenshot assertions. No second suite to maintain. 🧵 (1/4)

The @vitest/istanbuljs fork is now ready and will ship in the next version of Vitest. Compared to the original istanbuljs packages it's ESM-only, ships its own typings, drops unnecessary runtime deps, and moves Node 8→22, Babel 7→8 (lib-instrument), React→Preact (html-spa reporter), and more!

github.comRelease v1.0.0 · vitest-dev/istanbuljsv1.0.0 First stable release of @vitest/istanbuljs, a fork of istanbuljs/istanbuljs maintained by the Vitest team. The fork starts at upstream commit 28ffdbc (see vitest-dev/vitest#9433 for backgrou...
AriPerkkio@ariperkkio.dev

I'd like to avoid forking Istanbuljs monorepo just for Vitest. Any istanbuljs Github organization members here who could make me a maintainer there? (@kentcdodds.com, @jasonkurian.dev 👋) github.com/vitest-dev/v...

TIL when running Vitest browser mode (or plain Playwright) on Github Actions on Ubuntu, you can skip the slow "playwright install chromium" step completely by providing channel option. This makes Playwright use the pre-installed Chrome. So many projects out there that could speed their CIs with this

AriPerkkio reposted

is the distributed code readable? yes - don't ship a sourcemap. no - make the distributed code readable.

AriPerkkio reposted

Get first access to our @vitest.dev plugin, which adds Chromatic’s visual testing and review to your browser tests. It’s built by @ariperkkio.dev, a Vitest core maintainer. It’s free to use while in beta and requires no changes to your test files. Read on for more info 🧵

Building this integration has been amazing opportunity to dogfood all APIs we've added into @vitest.dev in past years. It's using features like new Reporter APIs, Vitest plugin hooks, browser commands, CDP, test tags and much more! Vitest is definitely one of the most extensible JS tools out there.

Chromatic@chromatic.com

We’re launching early access for Vitest visual testing with Chromatic! ⚡️ Built with @vitest.dev core maintainer ariperkkio.dev, Chromatic adds visual testing to the browser tests you already write. 🧵 (1/4)

If you've published a package using staged publishing before this fix, all that's needed now is to re-publish the same package and @npmx.dev will display the trusted publishing label again 🤝

James@43081j.com

npm now signals when a package used staged publishing! 🎉 this will fix a whole bunch of trust scales (e.g. pnpm trust downgrades)

Testing terminal output is hard. Especially in cases that involve clearing screen partially while maintaining stable log output elsewhere on screen. With ansivision it's possible to simulate what output all the ansi codes would render visually in real terminal. No need to use heavy node-pty anymore.

github.comGitHub - 43081j/ansivision: A library to time-travel through terminal output and more.A library to time-travel through terminal output and more. - 43081j/ansivision
James@43081j.com

Super happy to see a fairly niche library of mine being put to good use 😍

There's some impressive work going on with 3rd party oxc powered coverage instrumentation that can replace Babel based istanbul-lib-instrument 👀 > 8-11x faster than babel-plugin-istanbul, 13-15x faster than swc-plugin-coverage-instrument (Rust/WASM), 25-30x faster than istanbul-lib-instrument.

github.comGitHub - fallow-rs/oxc-coverage-instrument: Istanbul-compatible JavaScript/TypeScript coverage instrumentation using the Oxc ASTIstanbul-compatible JavaScript/TypeScript coverage instrumentation using the Oxc AST - fallow-rs/oxc-coverage-instrument

This day 4 years ago I sent my first PR to @vitest.dev. Back then it was on v0.7.4 with 80K weekly downloads. After one year and +70 more PRs, @antfu.me and @erus.dev invited me to join the team. Today we are at v4.1.0 with 35M weekly downloads. Maybe in 2030 we'll have Vitest 8 with 140M downloads.

github.comtest(reporters): add outputFile tests by AriPerkkio · Pull Request #978 · vitest-dev/vitestAdds missing test cases for outputFile configuration. I'm working on another bug fix and thought let's merge these ones first.

AriPerkkio reposted

Flaky tests and memory leaks are the worst. @vitest.dev now has a flag that catches uncleared intervals, lingering servers, and other async operations leaking across your tests. Available in the latest 4.1 beta. Big shout out to @ariperkkio.dev from the Vitest team for landing this PR! 🔥

In the next version of Vitest you can track leaking asynchronous resources via `--detect-async-leaks` option! Available in v4.1.0-beta.4 release. 🔍 (notice missing await in the example)

AriPerkkio reposted

Vitest hit 20 million weekly downloads in December, right before Christmas break. To put that into context: 5 million @vitest.dev weekly downloads were reached in June 2024, meaning a 4x increase in just 1.5 years. 🎉

When using vite@8-beta with Vitest users no longer need to add magical '@preserve' keywords in their coverage ignore hints. Originally this work-around was needed due to esbuild's (intentional) lack of support for comment preserving. Oxc has built-in support for JS coverage tools' ignore hints.

AriPerkkio reposted

Vitest 4.0.11 adds an experimental `fsModuleCache` flag to cache module transforms between reruns. Learn more: vitest.dev/config/exper... This is an opt-in feature, please let us know how it works for you! And example of a single test file that imports a lot of files (~1500). Almost a 50% boost!

Excited to see Typesafe CSF factories solve RFC I wrote two years ago. No more explicit TS typings! github.com/storybookjs/...

github.com[RFC] `defineMeta` helper function · storybookjs storybook · Discussion #25319Status: superseded by #30112 and implemented Summary Add a helper function defineMeta into Storybook that users can use to type the default export of stories. This helper function will provide type...
Storybook@storybook.js.org

Storybook 10 is here! ✂️ ESM-only (the only breaking change!) 🧩 Module automocking for easier testing 🏭 Typesafe CSF factories Preview for React 💫 UI editing and sharing optimizations 🏷️ Tag filtering exclusion for sidebar management 🔀 Svelte async component support

AriPerkkio reposted

My talk slides are available here hiroshi-talks.vercel.app/2025-10-25/1 also with source code in github.com/hi-ogawa/talks It was a great experience to talk with many awesome folks in person! Thanks @vuefes.bsky.social for the opportunity!

hiroshi-talks.vercel.appInside Vitest - Test Framework Architecture Deep Dive - Slidev
Vue Fes Japan@vuefes.bsky.social

/ 📢Introducing a speaker at Vue Fes Japan 2025✨ \ 【Hiroshi Ogawa @hiogawa.bsky.social 】 「Inside Vitest: Test Framework Architecture Deep Dive」 Check out the session details here✅ 👉 vuefes.jp/2025/en/spea... #vuefes #vuejs

After maintaining Tinypool for over 2 years I'm happy to see next version of Vitest dropping it. I've written some reasoning about this in the linked PR. Even though this change is significant for Vitest, I'm more confident about it than making new changes in Tinypool. github.com/vitest-dev/v...

github.comfeat!: rewrite pools without `tinypool` by AriPerkkio · Pull Request #8705 · vitest-dev/vitestDescription Removes Tinypool and adds new custom internal pool for Vitest only. Some previous thoughts I wrote ~2 months ago about this below. Vitest uses tinypool for orchestrating how test file...

Setting custom `process.title` in Node takes around 10-20ms. Vitest used to do this for every isolated test file so that debugging test runner processes was a bit nicer experience. But it's not worth the performance hit.

Vladimir@vladimir.berlin

Vitest 4 runs simple test files faster! You can already check it out by installing Vitest 4 beta. On average, Vitest now takes 25% less time to start the test. Due to parallelisation, the overall time difference can vary. We are focusing our efforts on improving the time even more in the next beta!

AST based V8 code coverage is finally here! I thought of this feature first time over 2 years ago, but knew it would require so much work that I couldn't finish it by working on Vitest just on weekends. Ever since @stackblitz.com hired me to work on Vitest I knew I could finish features like this.

Vitest@vitest.dev

Vitest 3.2 is out! - New Annotations API - Scoped Fixtures - Custom Browser Locators API - Test Signal - Better V8 Coverage Result And many more features! vitest.dev/blog/vitest-...

AST based V8 code coverage is finally here! I thought of this feature first time over 2 years ago, but knew it would require so much work that I couldn't finish it by working on Vitest just on weekends. Ever since @stackblitz.com hired me to work on Vitest I knew I could finish features like this.

Vitest@vitest.dev

Vitest 3.2 is out! - New Annotations API - Scoped Fixtures - Custom Browser Locators API - Test Signal - Better V8 Coverage Result And many more features! vitest.dev/blog/vitest-...

After couple of days looking at *.cpuprofile's, I think it's getting closer to stable v1 release. The ~3MB checker.ts from Typescript repo is perfect benchmarking reference for tools that process source code. When generating coverage for 'vuejs/core' repo, speed is close to original v8-to-istanbul.

AriPerkkio@ariperkkio.dev

Finalizing rewrite of AST-aware v8-to-istanbul. This will provide accuracy of Istanbul coverage for V8 coverage reports. I've intentionally kept this tool unopinionated so that it's not strictly tied to just @vitest.dev - it should be usable with Jest, C8, Playwright and node:test too.

This release includes long-awaited "--silent=passed-only" option, that can be used to hide console.log calls from passing tests. Only the logs from failing tests are reported.

Vitest@vitest.dev

Vitest 3.1.0 is out! ⚡ Apart from performance improvements and fixes, this release expands your test setup flexibility with new options. Check out the release notes here.

Finalizing rewrite of AST-aware v8-to-istanbul. This will provide accuracy of Istanbul coverage for V8 coverage reports. I've intentionally kept this tool unopinionated so that it's not strictly tied to just @vitest.dev - it should be usable with Jest, C8, Playwright and node:test too.

AriPerkkio reposted

Huge improvement for Vitest development workflow, thanks to isolated declaration! I didn't think the migration was possible until I see PRs by @sxzz.dev. Just started to sponsor Kevin for the amazing work!

github.comSponsor @sxzz on GitHub SponsorsAn open sourceror. Working on Vue, Vite, VueUse, and their ecosystems.
Rob Palmer@robpalmer.bsky.social

Three weeks ago @sxzz.dev updated Vitest to (mostly) adopt TypeScript's stricter Isolated Declarations mode 🎉 github.com/vitest-dev/v... This allowed @hiogawa.bsky.social to make Vitest use Oxc for DTS generation. Build time reduced from 90s to 27s - a 70% reduction 🔥 github.com/vitest-dev/v...

AriPerkkio reposted

Huge thanks to @sapphi.red for helping the @vitest.dev team with these findings. Perfect collaboration between projects. 🤝