Capture screenshots from iOS Simulators for all your Storybook stories,
compare them against baselines, and review changes in a self-hosted web dashboard.
- Automated Screenshot Capture - Captures screenshots from iOS Simulators for all Storybook stories
- Fast Image Comparison - Uses Pixelmatch with configurable thresholds and SSIM scoring
- Web Dashboard - Review visual changes with side-by-side, diff, overlay, and current-only views
- Story Browser - Flat list, tree (by component), and grouped (by directory) view modes
- Git Integration - Branch-based screenshot management
- CI/CD Ready - Upload results to the web dashboard from your CI pipeline
- macOS with Xcode installed
- Node.js >= 20
- React Native app with Storybook configured
- iOS Simulator
npm install -D @argus-vrt/cli
# or
yarn add -D @argus-vrt/cliyarn add -D @argus-vrt/cli
yarn argus initThis will auto-detect your Storybook configuration, find available iOS simulators, and create .argus.json with sensible defaults.
{
"scripts": {
"visual:test": "argus test",
"visual:baseline": "argus baseline --update"
}
}# Make sure your React Native app with Storybook is running
yarn ios
# Capture screenshots and set baselines
yarn visual:test --skip-upload
yarn visual:baseline
# Commit your baselines
git add .visual-baselines
git commit -m "chore: add visual baselines"# After making UI changes
yarn visual:test
# If changes are intentional, update baselines
yarn visual:baselineRun a complete visual test cycle: capture, compare, and upload (if configured).
argus test [options]
Options:
--skip-capture Use existing screenshots
--skip-upload Don't upload results
--base <branch> Base branch for comparison (default: main)
-t, --threshold Difference threshold 0-1 (default: 0.01)
Interactive setup wizard that auto-detects your project configuration.
argus init [--force]
Manage visual baselines.
argus baseline [options]
Options:
--update Update baselines from current screenshots
--clear Remove all baselines
Capture screenshots of all Storybook stories.
argus capture-all [options]
Options:
-b, --branch <branch> Override current git branch
-f, --filter <pattern> Filter stories by regex
--skip-shutdown Keep simulator running
Compare screenshots against baselines.
argus compare [options]
Options:
--base <branch> Base branch (default: main)
-t, --threshold <value> Difference threshold 0-1
--no-report Skip HTML report
Upload results to the web dashboard.
argus upload [--api-url <url>]
See the full command reference with all options in the @argus-vrt/cli README.
Configuration is stored in .argus.json in your project root. Run argus init to generate it.
| Field | Required | Default | Description |
|---|---|---|---|
storybook.port |
Yes | - | Storybook WebSocket port |
storybook.scheme |
Yes | - | iOS URL scheme for deep linking |
simulator.device |
Yes | - | Exact simulator device name |
simulator.bundleId |
Yes | - | App bundle identifier |
comparison.threshold |
No | 0.01 |
Pixel diff threshold (0-1) |
baselineDir |
No | .visual-baselines |
Directory for baseline images |
screenshotDir |
No | .visual-screenshots |
Directory for screenshots |
apiUrl |
No | - | Web dashboard URL for uploads |
Argus includes a self-hosted web dashboard (@argus-vrt/web) for reviewing visual diffs — similar to Chromatic, but self-hosted. It provides side-by-side diffs, overlay views with adjustable opacity, story browsing, search, and dark mode.
Deploy the dashboard with a single command:
# Interactive setup wizard — generates docker-compose.yml, .env, nginx.conf
npx @argus-vrt/web init
# Start the dashboard
npx @argus-vrt/web start
# Manage your deployment
npx @argus-vrt/web stop # Stop containers
npx @argus-vrt/web logs # Stream logs
npx @argus-vrt/web status # Health check
npx @argus-vrt/web upgrade # Pull latest image + restartThen point your CLI at it by adding apiUrl to your .argus.json:
{
"apiUrl": "http://localhost:3000"
}See the @argus-vrt/web README for all CLI options and configuration.
- Capture - Boots iOS simulator, launches your app with Storybook, navigates to each story via deep links, and captures screenshots
- Compare - Compares current screenshots against baselines using Pixelmatch, generates diff images highlighting changed pixels
- Upload - Sends results to the web dashboard API, which stores metadata in PostgreSQL
- Review - Use the web dashboard to review changes with overlay view showing exactly where pixels differ
Ensure the device name in .argus.json matches exactly:
xcrun simctl list devices- Verify
schemeandbundleIdin config - Check app is installed:
xcrun simctl listapps booted - Build app first:
yarn ios
- Select a story with changes (yellow percentage badge)
- Click the "Overlay" button
- Adjust the opacity slider
Ensure the web app server is running and can access the screenshot directories. See image serving options.
argus/
├── packages/
│ ├── cli/ # CLI tool (published as @argus-vrt/cli)
│ ├── web/ # Web dashboard (published as @argus-vrt/web)
│ └── shared/ # Shared types/constants (internal, bundled into CLI via tsup)
└── package.json # Yarn 4 workspaces + Turborepo
git clone https://github.com/maxcwolf/argus.git
cd argus
yarn install
yarn buildThe build compiles all three packages in dependency order via Turborepo: shared (tsc) → cli (tsup, inlines shared) → web (Vite).
# CLI — watch mode
yarn workspace @argus-vrt/cli dev
# Web — requires PostgreSQL via Docker
cd packages/web && docker compose up -d
yarn workspace @argus-vrt/web db:push
yarn workspace @argus-vrt/web dev- CLI: Node.js, TypeScript, tsup, Pixelmatch, Sharp, Commander
- Web: TanStack Start, TanStack Router, Drizzle ORM, Tailwind CSS v4, PostgreSQL
- Build: Turborepo, Yarn 4 workspaces
MIT