File size: 673 Bytes
c36dde2 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | # CSF Plugin
The CSF plugin reads CSF files and enriches their content via static analysis.
It supports Webpack, Vite, and other bundlers using [unplugin](https://github.com/unjs/unplugin).
## Source snippets
CSF plugin can add static source snippets to each story. For example:
```js
export const Basic = () => <Button />;
```
Would be transformed to:
```js
export const Basic = () => <Button />;
Basic.parameters = {
storySource: {
source: '() => <Button />',
},
...Basic.parameters,
};
```
This allows `@storybook/addon-docs` to display the static source snippet.
Learn more about Storybook at [storybook.js.org](https://storybook.js.org/?ref=readme).
|