Explore Component Interfaces with Storybook Controls

Michael Chan
InstructorMichael Chan
Share this video with your friends

Social Share Links

Send Tweet
Published a year ago
Updated 2 months ago

Uncover the power of Storybook Controls for interactively stress-testing component interfaces. Deepen your understanding of component behavior with real-time, interactive updates, enabling a thorough exploration of component capabilities.

[00:00] In Storybook, we can interactively explore and stress test components with controls. Controls turns every story into a component playground. To use controls, click the shortcut cog and make sure that show add ons is enabled. Then just make sure that controls is focused in the add ons panel. Storybook provides controls for every component [00:19] arg. So we have a primary arg which can be boolean true or false. A label arg which accepts a string. Background color, which takes a color. We can use this cool color picker for that. And size, which is innumerable represented by this radio button. Storybook automatically generates controls [00:39] for any component that uses the c s f three object syntax as you see here. ARGs are defined on a story and applied it to the component that's defined in component meta which we'll learn about later on. Unlike just rendering a component with the props applied, this arc system [00:59] involves storybook allowing it to know what types of controls it should use for these interfaces. With controls, more teammates can get involved in the component driven development process, helping do a QA, stress test, and communicate about designs together.

egghead
egghead

Member comments are a way for members to communicate, interact, and ask questions about a lesson.

The instructor or someone from the community might respond to your question Here are a few basic guidelines to commenting on egghead.io

Be on-Topic

Comments are for discussing a lesson. If you're having a general issue with the website functionality, please contact us at support@egghead.io.

Avoid meta-discussion

  • This was great!
  • This was horrible!
  • I didn't like this because it didn't match my skill level.
  • +1 It will likely be deleted as spam.

Code Problems?

Should be accompanied by code! Codesandbox or Stackblitz provide a way to share code and discuss it in context

Details and Context

Vague question? Vague answer. Any details and context you can provide will lure more interesting answers!

Markdown supported.
Become a member to join the discussionEnroll Today