Bug report
What is the current behavior?
Uncaught TypeError: Cannot read property 'call' of undefined
If the current behavior is a bug, please provide the steps to reproduce.
Minimal reproduction: https://github.com/mifopen/webpack-bug-example
@sentry/browser is used as an example of package with "sideEffects": false
Steps to reproduce:
- Clone the repo
- Run
yarn/npm run build-vendor
- Run
yarn/npm run build-app
- Open
index.html file in browser
- Open console to see error
Why?
Module LogLevel from @sentry/types (dep of @sentry/browser) is exported from the package but isn't used. webpack excludes it from DLL because of production mode and "sideEffects": false, but DllPlugin somehow requires it anyway.
What is the expected behavior?
Generate DLL without unused modules at all
Other relevant information:
webpack version: 4.31.0
Node.js version: 11.1
Operating System: macos 10.14.4