```js // YourComponent.stories.js import YourComponent from './YourComponent.svelte'; export default { /* 👇 The title prop is optional. * See https://storybook.js.org/docs/7.0/svelte/configure/overview#configure-story-loading * to learn how to generate automatic titles */ title: 'YourComponent', component: YourComponent, //👇 Creates specific argTypes argTypes: { propertyA: { options: ['Item One', 'Item Two', 'Item Three'], control: { type: 'select' }, // Automatically inferred when 'options' is defined }, propertyB: { options: ['Another Item One', 'Another Item Two', 'Another Item Three'], }, }, }; //👇 Some function to demonstrate the behavior const someFunction = (valuePropertyA, valuePropertyB) => { // Makes some computations and returns something }; /* *👇 Render functions are a framework specific feature to allow you control on how the component renders. * See https://storybook.js.org/docs/7.0/svelte/api/csf * to learn how to use render functions. */ export const ExampleStory = { render: ({ propertyA, propertyB }) => { //👇 Assigns the function result to a variable const someFunctionResult = someFunction(propertyA, propertyB); return { Component: YourComponent, props: { ...args, someProperty: someFunctionResult, }, }; }, args: { propertyA: 'Item One', propertyB: 'Another Item One', }, }; ```