[231223] 스토리보드 TS
스토리보드 TS
- TS같은 경우 Meta 로 타입을 정의해두고 사용하는 것이 좋음
import type { Meta, StoryObj } from "@storybook/react"
import { SurveyParticipantCountTable } from "./SurveyParticipantCountTable"
const meta: Meta<typeof SurveyParticipantCountTable> = {
component: SurveyParticipantCountTable,
}
export default meta
type Story = StoryObj<typeof SurveyParticipantCountTable>
export const Primary: Story = {
args: {
surveyCountData: [
{
name: "설문1",
totalCount: 100,
completeCount: 50,
progressCount: 50,
},
{
name: "설문2",
totalCount: 100,
completeCount: 50,
progressCount: 50,
},
],
backgroundColor: "#ffdfdf",
borderColor: "#ff7070",
},
}
Leave a comment