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

How to override existing webpack plugins #1314

Closed
Stupidism opened this issue Jun 18, 2017 · 3 comments
Closed

How to override existing webpack plugins #1314

Stupidism opened this issue Jun 18, 2017 · 3 comments

Comments

@Stupidism
Copy link
Contributor

I'm trying to serialize function in documentation.
I have a function

  const handler = (props, next) => (count) => {
    if (Math.random() < possibility) {
      next();
      log('hit', possibility, props, count);
    } else {
      log('miss', possibility, props, count);
    }
  };

And I used handler.toString() to print it out:
image

It's pretty good. But after uglify:
image

So I'm thinking If I can override the uglifyPlugin and turn off compress.

@Stupidism
Copy link
Contributor Author

Stupidism commented Jun 18, 2017

I am also trying to find a solution from uglifyJS: mishoo/UglifyJS#2118

@ndelangen
Copy link
Member

Here you go:
Webpack full control mode: https://storybook.js.org/configurations/custom-webpack-config/#full-control-mode

@ndelangen
Copy link
Member

Please re-open if you feel this doesn't solve your problem 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants