tech stack : shadcn , tailwind , typescript ,nextjs, storybook
i was able to make static but instead i want it to be dynamic
this is toaster.tsx i am new to the storybook so having difficulty
`import type { Meta, StoryObj } from '@storybook/react';
import { useToast } from '@/components/ui/use-toast/use-toast';
import { Toaster } from '../toaster/toaster';
import { Button } from '@/components/ui/button/button';
const meta: Meta<typeof Toaster> = {
component: () => {
const { toast } = useToast();
return (
<div>
<Button onClick={() => toast({ type: 'foreground', title: 'hello' })}>
Go for toast
</Button>
<Toaster />
</div>
);
},
args: {
color: 'red',
},
};`your text`
export default meta;
export const Default: StoryObj<typeof Toaster> = {
args: {},
};
`
New contributor
sam khan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.