Closed danyim closed 10 months ago
I assume, that you have configured @vitejs/plugin-react-swc
inside Storybook's main.<ts|js> configuration in the viteFinal
config?
Can you rather set the plugin in your vite.config.js
file?
I'll close this issue as we were able to resolve it by letting Storybook inherit our Vite settings without specifying a viteFinal
. Thank you for the response, @valentinpalkovic!
Describe the bug
Running Storybook in dev mode with HMR appears to break when refreshing with a
?path=...
URL param but not when navigating to root URL (i.e. http://localhost:6006). This appears to be because react-refresh wrappers are added twice when rendering a story with a URL param.This is occurring in Storybook v7.5.3 built using with
@vitejs/plugin-react-swc
.Error (in Chrome console):
Code:
.storybook/main.js
config:To Reproduce
No response
System
Additional context