thebushidocollective avatar

Storybook Story Writing

Handles Storybook story creation with a clear bias toward CSF3, which is the right call if you're not stuck on legacy code. Walks you through the modern object syntax, proper TypeScript typing with Meta and StoryObj, and patterns for common cases like forms, responsive variants, and data-driven components. The anti-patterns section is helpful, especially calling out the old Template.bind approach that still shows up in too many codebases. Worth using if your team keeps writing inconsistent stories or you're tired of reviewing PRs where someone reinvented decorators badly. Focuses on structure and conventions rather than visual testing.

skills.sh installs
678
GitHub stars
200
last updated
Aug 21, 2026

Install

$ npx -y skills add thebushidocollective/han --skill storybook-story-writing --agent claude-code

Installs into .claude/skills of the current project.

Files

Storybook - Story Writing

Write well-structured, maintainable Storybook stories using Component Story Format 3 (CSF3) that showcase component variations and ensure consistent rendering.

Key Concepts

Component Story Format 3 (CSF3)

CSF3 is the modern Storybook format that uses object syntax for stories:

import type { Meta, StoryObj } from '@storybook/react';
import { Button } from './Button';

const meta = {
  title: 'Components/Button',
  component: Button,
  parameters: {
    layout: 'centered',
  },
  tags: ['autodocs'],
  argTypes: {
    backgroundColor: { control: 'color' },
  },
} satisfies Meta<typeof Button>;

export default meta;
type Story = StoryObj<typeof meta>;

export const Primary: Story = {
  args: {
    primary: true,
    label: 'Button',
  },
};

export const Secondary: Story = {
  args: {
    label: 'Button',
  },
};

Story Organization

  • One story file per component: Component.stories.tsx
  • Use descriptive story names: Primary, Secondary, Large, Disabled
  • Group related stories under a title hierarchy: Components/Forms/Input

Default Export (Meta)

The default export defines metadata for all stories:

Sponsors

Details

Repository
github.com/thebushidocollective/han
Categories
Frontend Development, DevOps & CI/CD, Documentation, Code Review & Quality, Design & UI/UX
First seen
Jun 3, 2026

More from thebushidocollective/han

All 14
1bobmatnyc avatarcypressbobmatnyc/claude-mpm-skillsCypress end-to-end and component testing patterns for web apps: reliable selectors, stable waits, network stubbing, auth handling, CI parallelization, and flake664skills.sh installs
2proffesor-for-testing avatarcompatibility-testingproffesor-for-testing/agentic-qeCross-browser, cross-platform, and cross-device compatibility testing ensuring consistent experience across environments. Use when validating browser support, t654skills.sh installs
3fugazi avatarplaywright-e2e-testingfugazi/test-automation-skills-agentsAuthor and maintain versioned Playwright (@playwright/test) TypeScript UI specs for browser user flows. Use when asked to create, run, debug, or refactor E2E te634skills.sh installs
4patternsdev avatarprovider-patternpatternsdev/skillsTeaches the provider pattern for sharing data across component trees. Use when multiple nested components need access to the same data and prop drilling becomes634skills.sh installs
5astronomer avatarairflow-pluginsastronomer/agentsBuilds Airflow 3.1+ plugins that embed FastAPI apps, custom UI pages, React components, middleware, macros, and operator links directly into the Airflow UI. Use622skills.sh installs
6alirezarezvani avataremail-template-builderalirezarezvani/claude-skillsBuild complete transactional email systems: React Email templates, provider integration (Resend, Postmark, SendGrid, AWS SES), preview server, i18n support, dar613skills.sh installs