UNPKG

@storybook/addon-svelte-csf

Version:
27 lines (26 loc) 775 B
import pkg from '@storybook/addon-svelte-csf/package.json' with { type: 'json' }; /** * The export is defined in the `package.json` export map */ export function createRuntimeStoriesImport() { const imported = { type: 'Identifier', // WARN: Tempting to use `createRuntimeStories.name` here. // It will break, because this function imports `*.svelte` files. name: 'createRuntimeStories', }; return { type: 'ImportDeclaration', source: { type: 'Literal', value: `${pkg.name}/internal/create-runtime-stories`, }, specifiers: [ { type: 'ImportSpecifier', imported, local: imported, }, ], }; }