storybook
Installation
SKILL.md
Storybook
- ALWAYS use
mcp__storybook__get-storybook-story-instructionsbefore writing stories. - ALWAYS use
mcp__storybook__preview-storiesto preview stories after writing them. - Stories use
parameters.fixturesfor fixture overrides. - API mocking (handlers, fixtures, story-scoped overrides,
msw-storybook-addonwiring and its v2→v3 break):svelte-5:mswskill. - Storybook is usually already running: just navigate with Playwright MCP.
- Verify every story in the browser via Playwright MCP: don't assume it works.
- CSS imports: trace chains through BOTH
App.svelteAND.storybook/preview.ts. Moving imports out of the SCSS chain breaks Storybook unless also added topreview.tsorstorybook.scss.
Svelte 4 writable stores need wrapper components in stories
Components that import and read from Svelte 4 module-level
writable() stores (from svelte/store) render with default/
empty data in Storybook unless the stores are populated before
the component mounts. This does NOT apply to Svelte 5 runes-
based state in .svelte.ts modules, those are reactive on
their own.