agentsclimarketplace

Storybook

Skill G1Joshi/Agent-Skills/skills/testing/storybook

A comprehensive skill catalog for AI agents

Install
npx -y skills add G1Joshi/Agent-Skills --skill storybook

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 10 stars10 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Storybook UI component development and testing. Use for component testing.

SKILL.md

2.0 KB, as published. Nobody here has run it

Storybook

Storybook is a frontend workshop for building UI components and pages in isolation. It enables you to develop UI components without running your entire app (and logic/APIs).

When to Use

  • Component Libraries: Building a Design System.
  • Visual Testing: Visualizing all states of a component (Loading, Error, Empty).
  • Documentation: Auto-generating docs for your team.

Quick Start

npx storybook@latest init
npm run storybook

Snippet:

// Button.stories.tsx
import type { Meta, StoryObj } from "@storybook/react";
import { Button } from "./Button";

const meta: Meta<typeof Button> = {
  component: Button,
};
export default meta;

type Story = StoryObj<typeof Button>;

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

Core Concepts

Stories

A capture of a component in a specific state. A file can have multiple stories (Primary, Secondary, Disabled).

Controls

Auto-generated UI knobs that allow you to modify props (Change color, change text) live in the browser.

Addons

Plugins that extend functionality. Key ones:

  • Actions: Log events (onClick).
  • A11y: Check accessibility compliance.
  • Interactions: Run small tests inside the story (play function).

Best Practices (2025)

Do:

  • Use the play function: Allows interactive testing within Storybook (powered by Testing Library).
  • Use "Autodocs": Enable tags: ['autodocs'] to generate automatic documentation pages.
  • Visual Regression: Integrate with Chromatic (by Storybook maintainers) to detect visual changes in CI.

Don't:

  • Don't mix business logic: Components in Storybook should be "dumb" (Presentational). If they need data, pass it via args (mocks), don't fetch from APIs inside the component if possible.

References

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.