fix(@angular-devkit/build-angular): correctly set ngDevMode in esbuilder

During development we should not set `ngDevMode` to `true`, as this is expected to be an object literal.

Closes #23627
This commit is contained in:
Alan Agius 2022-07-22 12:50:15 +00:00 committed by Charles
parent c2c4cac13c
commit aa83feb373

View File

@ -346,7 +346,7 @@ async function bundleCode(
),
],
define: {
'ngDevMode': optimizationOptions.scripts ? 'false' : 'true',
...(optimizationOptions.scripts ? { 'ngDevMode': 'false' } : undefined),
'ngJitMode': 'false',
},
});