storybook/docs/snippets/vue/page-story-slots.2.js.mdx
2021-08-28 01:52:57 +01:00

25 lines
457 B
Plaintext

```js
// Page.stories.js
import Page from './Page.vue';
export default {
component: Page,
};
export const CustomFooter = {
args: {
footer: '<a href="https://storybook.js.org/">Built with Storybook</a>',
},
render: (args, { argTypes }) => ({
components: { Page },
props: Object.keys(argTypes),
template: `
<page v-bind="$props">
<footer v-if="footer" v-slot=footer v-html="footer"/>
</page>
`,
}),
};
```