Skip to content

Commit c146e9c

Browse files
bjarklerclydin
authored andcommitted
feat(@angular-devkit/build-angular): enable webpack Trusted Types support
As reported in #20113, webpack triggers a Trusted Types violation when lazy-loading is used. To mitigate that, enable webpack's Trusted Types module (introduced in webpack/webpack#9856) using 'angular#bundler' as the policy name.
1 parent 16a8031 commit c146e9c

File tree

1 file changed

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

1 file changed

+1
-0
lines changed

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

+1
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ export function getBrowserConfig(wco: WebpackConfigOptions): webpack.Configurati
8787
: 'web',
8888
output: {
8989
crossOriginLoading,
90+
trustedTypes: 'angular#bundler',
9091
},
9192
optimization: {
9293
runtimeChunk: 'single',

0 commit comments

Comments
 (0)