fbredius/storybook

View on GitHub
docs/snippets/common/my-component-story-with-storyname.js.mdx

Summary

Maintainability
Test Coverage
```js
// MyComponent.story.js|jsx|ts|tsx

import { MyComponent } from './MyComponent';

export default {
  /* 👇 The title prop is optional.
  * See https://storybook.js.org/docs/react/configure/overview#configure-story-loading
  * to learn how to generate automatic titles
  */
  title: 'Path/To/MyComponent', 
  component: MyComponent,
};

export const Simple = () => ({
  //👇 Your story goes here
});
Simple.decorators = [ ... ];
Simple.parameters = { ... };
Simple.storyName = 'So simple!';
```