Quokka.js vs Wallaby.js

A common question from Wallaby.js users is Why do I need Quokka.js? and How is it different? This page answers those questions and describes the differences between both products.

Quokka.js and Wallaby.js are different tools for two very different purposes. Both tools can execute code and display live results, but this is really the only overlap. While some features overlap as well (Live Comments, for example), how and when your code is executed is what really sets the two products apart.

Simply put, Wallaby.js is a test runner while Quokka.js is a scratchpad / playground.

Wallaby.js works at the project level and must be configured for each project whereas Quokka.js operates on a file level. Unlike Wallaby.js, you can run many Quokka.js instances per project. In most cases, Quokka.js does not need any configuration; when it does, usually one global configuration can be used for all projects. Unlike Wallaby.js, Quokka.js does not need to be run within a project - it can run on an external file. Quokka.js allows you to start writing and testing your code in a scratchpad without any setup.

Quokka.js is faster for simple scenarios because unlike Wallaby.js it doesn’t have to load a testing framework and initialize other unit testing specific components. Quickly launching a scratchpad is not the same as running all of your tests. However, unlike Wallaby.js, Quokka.js doesn’t support any testing frameworks and can’t watch / trigger / run tests.

Quokka.js can only display the live results from its single entry file whereas Wallaby.js displays results for your entire project. Wallaby.js also tracks which code is used by which tests and vice-versa and provides a rich interface to explore your project’s tests, their dependencies and test code coverage.

Wallaby.js supports both browser (Chrome, Electron, PhantomJs) and node runtime environments, while Quokka.js only runs in node. Wallaby.js also provides first class support for various UI frameworks (e.g. Angular, React, Vue) while Quokka.js does not.

Wallaby.js can only use your project’s node modules (or other node modules from disk), while Quokka.js supports temporary node modules (for each running instance); Quokka.js allows you to try a new module without polluting your project’s node modules folder.