Skip to content

Storybook for Primer CSS #1660

Description

@langermank

Is your feature request related to a problem? Please describe.
Outside of developing directly in the docs site, I didn't see a clear path towards building new CSS only components for Primer. I've seen some folks use codepen or a custom repo, but having a stable "playground" that comes with all the dependencies you need to contribute would be nice.

Describe the solution you'd like
Storybook is an out of the box solution that other Primer implementations are using (React and View Components). It's also somewhat universally understood, so onboarding new designers/developers could arguably be easier.

Describe alternatives you've considered
Storybook is the only tool I explored as I'm most familiar with it, and it was quick to configure.

Additional context

  • Primer CSS already contains React in the /docs directory for the Gatsby site
  • Writing stories as we build new CSS components allows us to work with conditional logic, leading to more robust solutions that handle edge cases
  • Writing stories with conditionals brings us one step closer to View Components (logic has been worked out, just needs to be hooked up)

Configuration is in the ActionList CSS PR, but I'll likely move it to its own PR

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions