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

Production mode minifies routerMiddleware of 'connected-react-router' as undefined #9159

Closed
knightus opened this issue May 21, 2019 · 4 comments · Fixed by #9176
Closed

Production mode minifies routerMiddleware of 'connected-react-router' as undefined #9159

knightus opened this issue May 21, 2019 · 4 comments · Fixed by #9176

Comments

@knightus
Copy link

Bug report

What is the current behavior?
Production mode of webpack 4.32.0 cannot minify connected-react-router middleware properly, and produces undefined

If the current behavior is a bug, please provide the steps to reproduce.

  • Using webpack 4.31.0, connected-react-router v6.4.0
  • Upgrade webpack from 4.31.0 to 4.32.0
  • Run build (production mode)
  • webpack minifies connected-react-router's middleware as undefined

This is a large proprietary project so I'm not sure how to extract this to a sample repo yet. But here's some screenshots from Chrome debugger (unminified)

image

What is the expected behavior?
Webpack minifies this middleware successfully as a function.

image
image

Other relevant information:
webpack version: 4.32.0
Node.js version: 11.13.0
Operating System: Windows 10
Additional tools: yarn 1.16.0

@sokra
Copy link
Member

sokra commented May 22, 2019

I can't reproduce it with the instructions above.

It would be great if you reduce your issue to a small reproducible example. Best put this example into a github repository together with instructions how to get to the problem.

@knightus
Copy link
Author

Hi @sokra,

I've created a repo trying to describe the problem better, please check and tell me if you need more information: https://github.com/knightus/webpack-issue-9159

@sokra
Copy link
Member

sokra commented May 22, 2019

Thanks this helps

@sokra
Copy link
Member

sokra commented May 22, 2019

fixed in 4.32.2

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

Successfully merging a pull request may close this issue.

2 participants