storybook/docs/snippets/svelte/my-component-with-env-variables.js.mdx
2021-08-28 01:52:57 +01:00

20 lines
291 B
Plaintext

```js
// MyComponent.stories.js
import MyComponent from './MyComponent.svelte';
export default {
component: MyComponent,
};
const Template = {
args: {
propertyA: process.env.STORYBOOK_DATA_KEY,
},
render: (args) => ({
Component: MyComponent,
props: args,
}),
};
```