mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-07 06:11:05 +08:00
34 lines
632 B
Markdown
34 lines
632 B
Markdown
```js filename=".storybook/preview.js" renderer="common" language="js"
|
|
import { CodeBlock } from './CodeBlock';
|
|
|
|
export default {
|
|
parameters: {
|
|
docs: {
|
|
components: {
|
|
code: CodeBlock,
|
|
},
|
|
},
|
|
},
|
|
};
|
|
```
|
|
|
|
```ts filename=".storybook/preview.ts" renderer="common" language="ts"
|
|
// Replace your-framework with the framework you are using (e.g., react, vue3)
|
|
import { Preview } from '@storybook/your-framework';
|
|
|
|
import { CodeBlock } from './CodeBlock';
|
|
|
|
const preview: Preview = {
|
|
parameters: {
|
|
docs: {
|
|
components: {
|
|
code: CodeBlock,
|
|
},
|
|
},
|
|
},
|
|
};
|
|
|
|
export default preview;
|
|
```
|
|
|