Skip to content

Commit b25775f

Browse files
committed
fix(@angular-devkit/build-angular): avoid build performance hit when using custom loader
loaders in esbuild aren't really custom code. You can only choose from the loaders that esbuild provides. So I doubt they require this `externalPackagesPlugin` which comes at a pretty steep cost of 1 second per 1500 imports your project has on every build and watch rebuild. fixes angular#27116
1 parent fcfba7a commit b25775f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

packages/angular_devkit/build_angular/src/tools/esbuild/application-code-bundle.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,8 @@ export function createBrowserCodeBundleOptions(
6565
}
6666

6767
if (options.externalPackages) {
68-
// Package files affected by a customized loader should not be implicitly marked as external
68+
// Package files affected by a customized plugin should not be implicitly marked as external
6969
if (
70-
options.loaderExtensions ||
7170
options.plugins ||
7271
typeof options.externalPackages === 'object'
7372
) {

0 commit comments

Comments
 (0)