-
-
Notifications
You must be signed in to change notification settings - Fork 1.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
Webpack UglifyJs plugin breaks the bundle #84
Comments
I didn’t see this on the demo page or in my project. Probably it’s a conflict with your project’s code so I’d like you to help me debug it. Also: which version of react-styleguidist do you use? |
I was on the |
Looks like Uglify removes it for some reason. |
Can you share your component definition? I can’t reproduce it. |
The reason is that I am using Interestingly this only failed for built version after minification but not for non-minified or server version. Would it make sense to allow components without |
Not sure about filename but if it works for unminified version I could try to disable name mangling in UglifyJS. |
Hm, mangling is already disabled. |
Yes, I also tried |
The only way I can reproduce it is |
Hi there! Thanks for this project! I have the same problem with The project is located here: https://github.com/urbica/react-map-gl Is there any way to disable minification on building style guide? I've tried to pass |
@stepankuzmin Works fine for me, except this warning:
Please open a new issue, most likely it’s not related to this one.
Very good, you should not make a production build with |
@sapegin thanks for the reply! Project setup requires Everything works fine on |
@stepankuzmin I’d better fix a bug if there is one ;-) But I can’t even reproduce it in your repo. Do I need access token to reproduce the issue?
|
When using the
styleguidist build
functionality, I get the following error in the browser console:I did some investigation, and it seems to be caused by the
UglifyJsPlugin
used in the webpack "production" config. Removing it solves the problem (also, increases the bundle size 3 times). It's quite hard to debug what is the actual problem in the minified bundle though.The text was updated successfully, but these errors were encountered: