Skip to content

Commit

Permalink
Add element polyfills to plugin exclusions
Browse files Browse the repository at this point in the history
  • Loading branch information
steverep committed May 4, 2024
1 parent ce2b52e commit 8de57f9
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions build-scripts/bundle.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -147,14 +147,17 @@ module.exports.babelOptions = ({ latestBuild, isProdBuild, isTestBuild }) => ({
overrides: [
{
// Add plugin to inject various polyfills, excluding the polyfills
// themselves to prevent self- injection.
// themselves to prevent self-injection.
plugins: [
[
path.join(BABEL_PLUGINS, "custom-polyfill-plugin.js"),
{ method: "usage-global" },
],
],
exclude: /\/node_modules\/(?:unfetch|proxy-polyfill)\//,
exclude: [
path.join(paths.polymer_dir, "src/resources/polyfills"),
/\/node_modules\/(?:unfetch|proxy-polyfill)\//,
],
},
{
// Use unambiguous for dependencies so that require() is correctly injected into CommonJS files
Expand Down

0 comments on commit 8de57f9

Please sign in to comment.