Skip to content

Commit

Permalink
fix(@angular-devkit/build-angular): avoid ES module assumption for ve…
Browse files Browse the repository at this point in the history
…ndor files

This change prevents import statements from being added to commonjs files when downleveling helpers are needed.  These imports would then cause webpack to assume that the file is an ES module and potentially break the commonjs file.

Fixes #18284
  • Loading branch information
clydin authored and filipesilva committed Jul 20, 2020
1 parent 67998b6 commit 411fe21
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -544,6 +544,7 @@ export function getCommonConfig(wco: WebpackConfigOptions): Configuration {
cacheIdentifier: JSON.stringify({
buildAngular: require('../../../../package.json').version,
}),
sourceType: 'unambiguous',
presets: [
[
require.resolve('@babel/preset-env'),
Expand Down

0 comments on commit 411fe21

Please sign in to comment.