storybook/docs/snippets/react/component-story-figma-integration.js.mdx
2022-07-07 19:47:29 +01:00

25 lines
524 B
Plaintext

```js
// MyComponent.stories.js|jsx
import React from 'react';
import { withDesign } from 'storybook-addon-designs';
import { MyComponent } from './MyComponent';
// More on default export: https://storybook.js.org/docs/7.0/react/writing-stories/introduction#default-export
export default {
title: 'FigmaExample',
component: MyComponent,
decorators: [withDesign],
};
export const Example = {
parameters: {
design: {
type: 'figma',
url: 'https://www.figma.com/file/Sample-File',
},
},
};
```