storybook/docs/snippets/svelte/storybook-addon-a11y-disable.js.mdx
2022-07-07 19:15:02 +01:00

33 lines
788 B
Plaintext

```js
// MyComponent.stories.js
import MyComponent from './MyComponent.svelte';
export default {
/* 👇 The title prop is optional.
* See https://storybook.js.org/docs/7.0/svelte/configure/overview#configure-story-loading
* to learn how to generate automatic titles
*/
title: 'Disable a11y addon',
component: MyComponent,
};
/*
*👇 Render functions are a framework specific feature to allow you control on how the component renders.
* See https://storybook.js.org/docs/7.0/svelte/api/csf
* to learn how to use render functions.
*/
export const NonA11yStory = {
render: (args) => ({
Component: MyComponent,
props: args,
}),
parameters: {
a11y: {
// This option disables all a11y checks on this story
disable: true,
},
},
};
```