You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// src: https://storybook.js.org/docs/react/get-started/whats-a-story/// Button.stories.ts|tsximportReactfrom'react';import{ComponentStory,ComponentMeta}from'@storybook/react';import{Button,ButtonProps}from'./Button';exportdefault{/* 👇 The title prop is optional. * See https://storybook.js.org/docs/react/configure/overview#configure-story-loading * to learn how to generate automatic titles */title: 'Button',component: Button,}asComponentMeta<typeofButton>;//👇 We create a “template” of how args map to renderingconstTemplate: ComponentStory<typeofButton>=(args)=><Button{...args}/>;exportconstPrimary=Template.bind({});Primary.args={primary: true,label: 'Button',};
Feature Request
Add more essential addons to the current setup (e.g. nextjs router, data handling as soon as we add #12 for instance).
Basic example
Motivation
Make it easier for starters to use Storybook and make the most out of it.
The text was updated successfully, but these errors were encountered: