Open oxymc opened 5 months ago
Do you have a repo where I can look ?
Import should be analyzed with a warning/Reallocation of the story with the same name.
For me the issue comes with import "conflicts"
// menu.svelte
import { Menu } from './menu-base.svelte';
=> docgen error, object is not extensible
if we rename to
import { Menu as Base } from './menu-base.svelte';
it works.
I wasn't sure if the error came from this library, storybook, vite or esm lol
@basselalsayed can you share a repository that demonstrates this problem?
@JReinhold yeah here you go https://github.com/basselalsayed/svelte-storybook-csf-issue
in select.svelte, try renaming the import and it works fine
Describe the bug
Can't use:
import { Menu } from './index';
inindex.stories.svelte
(but it works, if 'Menu' will be changed by other word: 'DropdownMenu' for example)Steps to reproduce the behavior
npm create svelte@latest <name-of-app>
npx storybook init
Expected behavior
More details are in screenshots
Screenshots and/or logs
Environment
Additional context
Will be good to know which words are 'forbidden' too, but will be great to fix it :)