storybook/docs/snippets/common/storybook-addons-api-useapi.js.mdx
2020-10-07 12:23:34 +08:00

9 lines
168 B
Plaintext

```js
// .storybook/my-addon/register.js
export const Panel = () => {
const state = useStorybookApi();
return <div>do something with storybook's api</div>;
};
```