-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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]: Jsx disapear from chrome dev tools source after migration to storybook 7 #26047
Comments
I have a similar issue with Storybook 7 with Include in webpack plugin: devtool: false, // handle by plugin
plugins: [
new webpack.SourceMapDevToolPlugin({
test: /jsx?.iframe.bundle.js$/,
exclude: /^vendors-.+$/, // optimization
filename: '[file].map', // can be omitted for inline source maps
moduleFilenameTemplate: 'webpack://[namespace]/[absolute-resource-path]', // can be omitted as above
module: false, // required, for some reason
}),
]
diff --git a/dist/index.js b/dist/index.js
index a1ca362e78c4abf50b73c6c567fd09175be9153e..6ad88f42f9fc3e897acbb85e28f8df04dbdd31a4 100644
--- a/dist/index.js
+++ b/dist/index.js
@@ -14,7 +14,6 @@
const pathRemainder = path.substring(${directory.length+1});
return import(
- /* webpackChunkName: "[request]" */
/* webpackInclude: ${webpackIncludeRegexp(specifier)} */
'${directory}/' + pathRemainder
);
diff --git a/dist/index.mjs b/dist/index.mjs
index 5af8560bd8fd4d66d66ea0af4fdf14af19e99b14..836ed5dc335fce56fd9f604edecb650f02b616ba 100644
--- a/dist/index.mjs
+++ b/dist/index.mjs
@@ -19,7 +19,6 @@ var webpackConfigs=["webpack.config","webpackfile"],loadCustomWebpackConfig=conf
const pathRemainder = path.substring(${directory.length+1});
return import(
- /* webpackChunkName: "[request]" */
/* webpackInclude: ${webpackIncludeRegexp(specifier)} */
'${directory}/' + pathRemainder
); After I can set break points in devtools, although the |
Many moving parts here, but I'm also in middle of a migration from storybook 6.5.13 to 7.6.17 and have the same issue. I think I've narrowed it to being related to an interaction with either I'm using
then sourcemaps are found as I expect. If i include one or both of those addons, e.g.
sourcemaps are missing in devtools |
Thanks for the feedback, unfortunately it does work with my project. |
I'm facing the same problem with Storybook 8, and disabling both |
It could potentially be a problem with
|
FYI: I am still missing source maps after upgrading to 8.0.5 I even tried updating my config with: (as suggested above) typescript: {
check: false,
skipCompiler: false,
reactDocgen: 'react-docgen-typescript' as const, // Adding this worked for sourcemaps
reactDocgenTypescriptOptions: {}
}, But that still did not work. Not really sure how to debug this or what I could provide, may well be something I am doing. However, if I downgrade to 7.6.17 all of the source maps come back (with no other changes). |
The fix in #26676 isn’t released yet and will be part of the 8.0.6 release. |
Awesome, thank you for that clarification |
Thanks @valentinpalkovic, |
Describe the bug
I made a storybook migration from 6.5.16 to 7.6.16 with the command npx [email protected] upgrade and applying all the proposed migration scripts.
Then I run storybook and tried to find my jsx components in the chrome source dev tools and can unfortunately can not find them.
To Reproduce
Reproduced with a simple project https://stackblitz.com/edit/stackblitz-starters-vjugfk?file=src%2FMyButton.style.js
in storybook 6.5.16 we can find MyButton.jsx in the source dev tools.
After migration to 7.6.16 we can only see MyButton.style.js
By comparing the source maps between the 2 cases :
find attached the generated bundle.
main.iframe.bundle.js.txt
stories-MyButton-stories.iframe.bundle.js.txt
System
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: