mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-08 02:21:48 +08:00
Added docs to show how to override SB block when using MDX
This commit is contained in:
parent
51b1739038
commit
782600b376
@ -60,6 +60,22 @@ addParameters({
|
|||||||
});
|
});
|
||||||
```
|
```
|
||||||
|
|
||||||
|
You can even override a Storybook *block* component.
|
||||||
|
|
||||||
|
Here's how you might insert a custom `<Preview />` block:
|
||||||
|
|
||||||
|
```js
|
||||||
|
import { PreviewBlock } from './PreviewBlock';
|
||||||
|
|
||||||
|
addParameters({
|
||||||
|
docs: {
|
||||||
|
components: {
|
||||||
|
Preview: PreviewBlock,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
});
|
||||||
|
```
|
||||||
|
|
||||||
## More resources
|
## More resources
|
||||||
|
|
||||||
Want to learn more? Here are some more articles on Storybook Docs:
|
Want to learn more? Here are some more articles on Storybook Docs:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user