diff --git a/build-scripts/bundle.cjs b/build-scripts/bundle.cjs index e0503a7a7313..deb7cada51ac 100644 --- a/build-scripts/bundle.cjs +++ b/build-scripts/bundle.cjs @@ -154,7 +154,10 @@ module.exports.babelOptions = ({ latestBuild, isProdBuild, isTestBuild }) => ({ { method: "usage-global" }, ], ], - exclude: /\/node_modules\/(?:unfetch|proxy-polyfill)\//, + exclude: [ + /\/src\/resources\/polyfills\//, + /\/node_modules\/(?:unfetch|proxy-polyfill)\//, + ], }, { // Use unambiguous for dependencies so that require() is correctly injected into CommonJS files