Using "node-polyfill-webpack-plugin": "^4.0.0" after just ejecting on latest react scripts (5.0.1) with Node 16.
In the config
// other imports
const NodePolyfillPlugin = require('node-polyfill-webpack-plugin');
// other config
plugins: [
new NodePolyfillPlugin(),
new ModuleScopePlugin(...)
]
the rest is exactly what eject gives. I tried commenting ModuleScopePlugin but that didn't do anything.
I can verify that ProvidePlugin doesn't exist anywhere within my codebase, and looks like it's something inherent to webpack