storybook/docs/snippets/vue/component-story-mdx-story-by-name.mdx-3.mdx.mdx
2021-08-08 18:33:11 +01:00

19 lines
347 B
Plaintext

```md
<!-- Button.stories.mdx --->
import { Story } from '@storybook/addon-docs';
import Button from './Button.vue';
export const Template = (args) => ({
components: { Button },
setup() {
return { args };
},
template: '<Button v-bind="args" />',
});
<Story name='Basic' args={{ label: 'hello' }}>
{Template.bind({})}
</Story>
```