Skip to content

Commit c80a92a

Browse files
clydinalexeagle
authored andcommitted
fix(@schematics/angular): skip E2E projects when migrating browserslist
1 parent 9b5653b commit c80a92a

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

+5-2
Original file line numberDiff line numberDiff line change
@@ -95,14 +95,17 @@ function updateBrowserlist(): Rule {
9595
}
9696

9797
// For all projects
98-
for (const projectName of Object.keys(angularJson.projects)) {
99-
const project = angularJson.projects[projectName];
98+
for (const [name, project] of Object.entries(angularJson.projects)) {
10099
if (!isJsonObject(project)) {
101100
continue;
102101
}
103102
if (typeof project.root != 'string' || project.projectType !== 'application') {
104103
continue;
105104
}
105+
if (name.endsWith('-e2e')) {
106+
// Skip existing separate E2E projects
107+
continue;
108+
}
106109

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

0 commit comments

Comments
 (0)