Skip to content

Commit 95bf71b

Browse files
committed
fix(@schematics/angular): skip E2E projects when migrating browserslist
1 parent 629396e commit 95bf71b

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

packages/schematics/angular/migrations/update-8/differential-loading.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,14 +88,17 @@ function updateBrowserlist(): Rule {
8888
}
8989

9090
// For all projects
91-
for (const projectName of Object.keys(angularJson.projects)) {
92-
const project = angularJson.projects[projectName];
91+
for (const [name, project] of Object.entries(angularJson.projects)) {
9392
if (!isJsonObject(project)) {
9493
continue;
9594
}
9695
if (typeof project.root != 'string' || project.projectType !== 'application') {
9796
continue;
9897
}
98+
if (name.endsWith('-e2e')) {
99+
// Skip existing separate E2E projects
100+
continue;
101+
}
99102

100103
const browserslistPath = join(normalize(project.root), '/browserslist');
101104
const source = tree.read(browserslistPath);

0 commit comments

Comments
 (0)