diff --git a/packages/webpack-why/index.js b/packages/webpack-why/index.js index 05eefb93..375be0ac 100644 --- a/packages/webpack-why/index.js +++ b/packages/webpack-why/index.js @@ -1,7 +1,8 @@ -import StatoscopeWebpackPlugin from '@statoscope/webpack-plugin' +import _StatoscopeWebpackPlugin from '@statoscope/webpack-plugin' import { join } from 'node:path' function addStatoscope(limitConfig, check, webpackConfig) { + const StatoscopeWebpackPlugin = _StatoscopeWebpackPlugin.default ?? _StatoscopeWebpackPlugin if (limitConfig.why) { let shouldOpen = process.env.NODE_ENV !== 'test' && !limitConfig.saveBundle