Skip to content

Commit 3036a5d

Browse files
committed
fix(@angular-devkit/build-angular): add web-streams-polyfill to downlevel exclusion list
Polyfill related packages should not be downlevelled due to the nature of their code which may need to perform feature testing or leverage native capabilities to extract browser support information necessary to properly polyfill a given browser. In the case of `web-streams-polyfill`, it leverages the `%AsyncIteratorPrototype%`, when available, to fully polyfill its stream implementations. To access `%AsyncIteratorPrototype%`, a native async generator is needed and therefore the code present in the package cannot have this case of a native async generator downlevelled. `core-js` is also excluded for similar (and additional reasons).
1 parent 36ee8cf commit 3036a5d

File tree

1 file changed

+1
-1
lines changed
  • packages/angular_devkit/build_angular/src/webpack/configs

1 file changed

+1
-1
lines changed

packages/angular_devkit/build_angular/src/webpack/configs/common.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ export function getCommonConfig(wco: WebpackConfigOptions): Configuration {
370370
test: /\.[cm]?js$|\.tsx?$/,
371371
// The below is needed due to a bug in `@babel/runtime`. See: https://github.com/babel/babel/issues/12824
372372
resolve: { fullySpecified: false },
373-
exclude: [/[/\\](?:core-js|@babel|tslib|web-animations-js)[/\\]/],
373+
exclude: [/[/\\](?:core-js|@babel|tslib|web-animations-js|web-streams-polyfill)[/\\]/],
374374
use: [
375375
{
376376
loader: require.resolve('../../babel/webpack-loader'),

0 commit comments

Comments
 (0)