mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-09 00:19:13 +08:00
17 lines
371 B
Plaintext
17 lines
371 B
Plaintext
```md
|
|
<!-- MyComponent.stories.mdx -->
|
|
|
|
import { Canvas, Meta, Story } from '@storybook/addon-docs';
|
|
|
|
import { MyComponent } from './MyComponent';
|
|
|
|
<Meta title="MyComponent" component={MyComponent}/>
|
|
|
|
<Canvas>
|
|
<Story
|
|
name="ExampleStory"
|
|
args={{
|
|
exampleProp: process.env.EXAMPLE_VAR,
|
|
}} render={() => ({ // Your implementation here })} />
|
|
</Canvas>
|
|
``` |