describe(me) docs
early v0.12.1 browser mode · jsdom Live · Foundations
Examples npm GitHub

Why describe-me

Stories drift from components because nothing runs them. Tests do run. describe-me makes the tests the documentation.

What you get #

Tests that render some other way are left out, see what is left out.

Compared with Storybook #

Storybook is the established tool for component documentation, with a large community. If you know it, this table maps its ideas onto describe-me.

Storybook describe-me Notes
Story An it test A test that renders a component is a story, named after the test.
Canvas A test in Live In Live the test mounts as its arrange phase set it up. The recorded frames show the steps after it.
Args Props passed to render The viewer shows the props each test passed.
Decorators The wrapper in your test utils Providers and global styles wrap each render, as they do in your tests.
preview-head.html previewHead HTML added to the head of every frame, such as font links. You can read an existing preview-head.html into it.
Play function The test body Each interaction leaves a frame. The assertions are the test's own.
Actions vi.fn() props in Live Each call shows in the inspector under the prop's name.
Autodocs The component overview The props table, with the values your tests cover.
ColorPalette and Typeset doc blocks in MDX Foundations Tokens read from the CSS the tests load, the Tailwind 4 theme and an optional theme module, with presets for Tailwind, shadcn/ui and Material UI. Nothing to write or keep in sync.
Controls A props table without inputs Live exists, controls do not. You cannot change props in the viewer yet. See the roadmap.
Addons None Storybook has a large addon ecosystem. describe-me has no plugin system.
Visual tests (such as Chromatic) None describe-me records DOM and CSS and compares nothing.
Static build describe-me build Both produce a static site any static host can serve. describe-me build --live makes the site mount tests too.

Newer Storybook versions can run your stories as Vitest tests. describe-me goes the other way and turns your tests into stories. If your stories are where your examples live, stay with Storybook. If your tests are, describe-me documents them as they are.

What it costs #

Recording makes every recorded test take longer. Performance has the measurements and ways to cut the cost.

When it is not the right tool #