storybook build). Older builds are rejected before upload, with the detected version in the error.
Authenticates with a project API key — a personal access token is rejected.
This command was called
ovr snapshot storybook before. That name still works and
behaves identically, but it prints a deprecation notice and will be removed in a
future release.Flags
By default the command uploads the build, then prints the build page URL and exits
0 as soon as the build is published — it doesn’t wait for processing or review.
Pass --wait to block until the build resolves or --timeout elapses instead. Exit code then reflects the outcome:
Only affected stories
Pass--only-affected to capture only the stories a change can affect. Every other story is listed on the build as skipped and keeps its baseline. Stories without a baseline for a viewport are always captured.
It needs:
- Storybook built with
--stats-jsonby the Vite, Webpack 5 or Rspack (storybook-builder-rsbuild) builder, andovrrun from the directory it was built in. - The full git history. In GitHub Actions, check out with
fetch-depth: 0. - A successful build on the project’s main branch in the commit’s history to compare against.
onlyAffected in ovr.config for files that affect stories without being imported.
We recommend it for pull requests only, and capturing every story on the main branch.
CI example
ovr.config, unless overridden with per-story parameters.