Installation (Playwright)
Install the packages
Section titled “Install the packages”pnpm add -D @playwright/test executable-stories-playwright executable-stories-formattersOr with npm:
npm install -D @playwright/test executable-stories-playwright executable-stories-formattersAdd the reporter
Section titled “Add the reporter”In playwright.config.ts, add the reporter using the package path so Playwright loads it correctly:
import { defineConfig } from '@playwright/test';
export default defineConfig({ reporter: [ ['list'], [ 'executable-stories-playwright/reporter', { formats: ['markdown'], outputDir: 'docs', outputName: 'user-stories', output: { mode: 'aggregated' }, }, ], ], // ... rest of config});Default output
Section titled “Default output”With the option above, the reporter writes to docs/user-stories.md. Run your tests:
pnpm playwright testThe Markdown file is generated after the test run.
First Story (Playwright) — write your first scenario.
Playwright reporter options — all configuration options.