mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-07 07:01:21 +08:00
3.8 KiB
3.8 KiB
import type { Meta } from from '@storybook/angular';
import { YourComponent } from './YourComponent.component';
const meta: Meta<YourComponent> = {
component: YourComponent,
parameters: { controls: { sort: 'requiredFirst' } },
};
export default meta;
<script module>
import { defineMeta } from '@storybook/addon-svelte-csf';
import YourComponent from './YourComponent.svelte';
const { Story } = defineMeta({
component: YourComponent,
parameters: { controls: { sort: 'requiredFirst' } },
});
</script>
import YourComponent from './YourComponent.svelte';
export default {
component: YourComponent,
parameters: { controls: { sort: 'requiredFirst' } },
};
import { YourComponent } from './YourComponent';
export default {
component: YourComponent,
parameters: { controls: { sort: 'requiredFirst' } },
};
<script module>
import { defineMeta } from '@storybook/addon-svelte-csf';
import YourComponent from './YourComponent.svelte';
const { Story } = defineMeta({
component: YourComponent,
parameters: { controls: { sort: 'requiredFirst' } },
});
</script>
import type { Meta } from '@storybook/svelte';
import YourComponent from './YourComponent.svelte';
const meta = {
component: YourComponent,
parameters: { controls: { sort: 'requiredFirst' } },
} satisfies Meta<typeof YourComponent>;
export default meta;
// Replace your-framework with the name of your framework
import type { Meta } from '@storybook/your-framework';
import { YourComponent } from './YourComponent';
const meta = {
component: YourComponent,
parameters: { controls: { sort: 'requiredFirst' } },
} satisfies Meta<typeof YourComponent>;
export default meta;
<script module>
import { defineMeta } from '@storybook/addon-svelte-csf';
import YourComponent from './YourComponent.svelte';
const { Story } = defineMeta({
component: YourComponent,
parameters: { controls: { sort: 'requiredFirst' } },
});
</script>
import type { Meta } from '@storybook/svelte';
import YourComponent from './YourComponent.svelte';
const meta: Meta<typeof YourComponent> = {
component: YourComponent,
parameters: { controls: { sort: 'requiredFirst' } },
};
export default meta;
// Replace your-framework with the name of your framework
import type { Meta } from '@storybook/your-framework';
import { YourComponent } from './YourComponent';
const meta: Meta<typeof YourComponent> = {
component: YourComponent,
parameters: { controls: { sort: 'requiredFirst' } },
};
export default meta;
export default {
component: 'your-component',
parameters: { controls: { sort: 'requiredFirst' } },
};
import type { Meta } from '@storybook/web-components';
const meta: Meta = {
component: 'your-component',
parameters: { controls: { sort: 'requiredFirst' } },
};
export default meta;