Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Add new component UI fails with "importers[path] is not a function" #30431

Closed
shilman opened this issue Jan 31, 2025 · 1 comment · Fixed by #30438
Closed

[Bug]: Add new component UI fails with "importers[path] is not a function" #30431

shilman opened this issue Jan 31, 2025 · 1 comment · Fixed by #30438

Comments

@shilman
Copy link
Member

shilman commented Jan 31, 2025

Describe the bug

In a new react-vite project when I try to add stories for App.tsx from the UI, it fails with an error importers[path] is not a function and requires a browser refresh to succeed.

Reproduction link

N/A

Reproduction steps

  1. Initialize a new react-vite project in an empty directory
  2. Click the + button next to the search UI
  3. Filter by **/*.tsx
Image 4. Select `App.tsx` and observe the following error Image 5. Refresh the browser and see the story render successfully Image

System

Storybook Environment Info:

  System:
    OS: macOS 15.1.1
    CPU: (10) arm64 Apple M1 Pro
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.18.2 - /usr/local/bin/node
    Yarn: 1.22.22 - /usr/local/bin/yarn
    npm: 10.8.2 - /usr/local/bin/npm <----- active
  Browsers:
    Chrome: 132.0.6834.160
    Safari: 18.1.1
  npmPackages:
    @storybook/addon-essentials: ^8.5.2 => 8.5.2 
    @storybook/addon-onboarding: ^8.5.2 => 8.5.2 
    @storybook/blocks: ^8.5.2 => 8.5.2 
    @storybook/experimental-addon-test: ^8.5.2 => 8.5.2 
    @storybook/react: ^8.5.2 => 8.5.2 
    @storybook/react-vite: ^8.5.2 => 8.5.2 
    @storybook/test: ^8.5.2 => 8.5.2 
    eslint-plugin-storybook: ^0.11.2 => 0.11.2 
    storybook: ^8.5.2 => 8.5.2

Additional context

No response

@shilman
Copy link
Member Author

shilman commented Feb 1, 2025

After some bisecting, I found that this broke in https://github.com/storybookjs/storybook/releases/tag/v8.3.0-beta.5

@github-project-automation github-project-automation bot moved this from Needs Discussion to Done in Core Team Projects Feb 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant