storybook/docs/snippets/svelte/my-component-with-env-variables.native-format.mdx
2021-11-06 03:20:29 +00:00

25 lines
403 B
Plaintext

```html
<!-- MyComponent.stories.svelte -->
<script>
import { Meta, Template, Story } from '@storybook/addon-svelte-csf';
import MyComponent from './MyComponent.svelte';
</script>
<Meta
title="MyComponent"
component={MyComponent}
/>
<Template let:args>
<MyComponent {...args} />
</Template>
<Story
name="ExampleStory"
args={{
propertyA: process.env.STORYBOOK_DATA_KEY,
}}
/>
```