Setting output.globalObject breaks parsed + gzip

Author: ntuckerCreated Jun 23, 2019Updated Jul 5, 2019
LabelsStatus: Needs details / reproductionstatus: Needs triage

Issue description

javascript
config.output.globalObject = "(typeof self !== 'undefined' ? self : this)"

Breaks parsed + gzip sizes. Removing it fixed them.

Technical info

  • Webpack Bundle Analyzer version: 3.3.2
  • Webpack version: 4.35.0
  • Node.js version: 11.10.0
  • npm/yarn version: 6.7.0
  • OS: mac os x; windows

Expected Behavior

Gzip and parsed should contain data bout more than just the output files - the modules inside them as well.

Actual Behavior

Only stats includes all modules. Gzip and parsed just show large blocks for each bundle piece (output file)

Code

My default:

javascript
config.output.globalObject = "(typeof self !== 'undefined' ? self : this)"

When I analyze:

javascript
delete config.output.globalObject;

Source: webpack/webpack-bundle-analyzer