Skip to content

Commit

Permalink
feat(angular): support angular 14.0.0-next.9
Browse files Browse the repository at this point in the history
  • Loading branch information
leosvelperez committed Mar 29, 2022
1 parent d33a341 commit 228ccb2
Show file tree
Hide file tree
Showing 17 changed files with 797 additions and 862 deletions.
52 changes: 15 additions & 37 deletions docs/generated/packages/angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -2042,7 +2042,8 @@
"properties": {
"input": {
"type": "string",
"description": "The file to include."
"description": "The file to include.",
"pattern": "\\.[cm]?jsx?$"
},
"bundleName": {
"type": "string",
Expand All @@ -2058,7 +2059,11 @@
"additionalProperties": false,
"required": ["input"]
},
{ "type": "string", "description": "The file to include." }
{
"type": "string",
"description": "The file to include.",
"pattern": "\\.[cm]?jsx?$"
}
]
}
},
Expand All @@ -2073,7 +2078,8 @@
"properties": {
"input": {
"type": "string",
"description": "The file to include."
"description": "The file to include.",
"pattern": "\\.(?:css|scss|sass|less|styl)$"
},
"bundleName": {
"type": "string",
Expand All @@ -2089,7 +2095,11 @@
"additionalProperties": false,
"required": ["input"]
},
{ "type": "string", "description": "The file to include." }
{
"type": "string",
"description": "The file to include.",
"pattern": "\\.(?:css|scss|sass|less|styl)$"
}
]
}
},
Expand Down Expand Up @@ -2344,15 +2354,9 @@
"description": "Extract all licenses in a separate file.",
"default": true
},
"showCircularDependencies": {
"type": "boolean",
"description": "Show circular dependency warnings on builds.",
"default": false,
"x-deprecated": "The recommended method to detect circular dependencies in project code is to use either a lint rule or other external tooling."
},
"buildOptimizer": {
"type": "boolean",
"description": "Enables '@angular-devkit/build-optimizer' optimizations when using the 'aot' option.",
"description": "Enables advanced build optimizations when using the 'aot' option.",
"default": true
},
"namedChunks": {
Expand Down Expand Up @@ -2567,32 +2571,6 @@
}
]
},
"extraEntryPoint": {
"oneOf": [
{
"type": "object",
"properties": {
"input": {
"type": "string",
"description": "The file to include."
},
"bundleName": {
"type": "string",
"pattern": "^[\\w\\-.]*$",
"description": "The bundle name for this extra entry point."
},
"inject": {
"type": "boolean",
"description": "If the bundle will be referenced in the HTML file.",
"default": true
}
},
"additionalProperties": false,
"required": ["input"]
},
{ "type": "string", "description": "The file to include." }
]
},
"budget": {
"type": "object",
"properties": {
Expand Down
8 changes: 4 additions & 4 deletions e2e/angular-core/src/ng-add.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,13 +81,13 @@ describe('convert Angular CLI workspace to an Nx workspace', () => {
updateFile('tsconfig.json', JSON.stringify(tsConfig, null, 2));

// add an extra script file
updateFile('src/scripts.ts', 'const x = 1;');
updateFile('src/scripts.js', 'const x = 1;');

// update angular.json
const angularJson = readJson('angular.json');
angularJson.projects[project].architect.build.options.scripts =
angularJson.projects[project].architect.test.options.scripts = [
'src/scripts.ts',
'src/scripts.js',
];
angularJson.projects[project].architect.test.options.styles = [
'src/styles.css',
Expand Down Expand Up @@ -206,7 +206,7 @@ describe('convert Angular CLI workspace to an Nx workspace', () => {
`apps/${project}/src/assets`,
],
styles: [`apps/${project}/src/styles.css`],
scripts: [`apps/${project}/src/scripts.ts`],
scripts: [`apps/${project}/src/scripts.js`],
},
configurations: {
production: {
Expand Down Expand Up @@ -261,7 +261,7 @@ describe('convert Angular CLI workspace to an Nx workspace', () => {
`apps/${project}/src/assets`,
],
styles: [`apps/${project}/src/styles.css`],
scripts: [`apps/${project}/src/scripts.ts`],
scripts: [`apps/${project}/src/scripts.js`],
},
});

Expand Down
6 changes: 1 addition & 5 deletions e2e/utils/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -190,14 +190,10 @@ export function runNgNew(
): string {
projName = projectName;

// Use the latest version of the currently supported @angular/cli major version
// to cover existing usage out there while avoiding the tests to fail when a new
// major comes out and is still not supported
const ngCliMajorVersion = coerce(angularCliVersion).major;
const npmMajorVersion = getNpmMajorVersion();
const command = `npx ${
+npmMajorVersion >= 7 ? '--yes' : ''
} @angular/cli@${ngCliMajorVersion} new ${projectName} --package-manager=${packageManager}`;
} @angular/cli@${angularCliVersion} new ${projectName} --package-manager=${packageManager}`;

return execSync(command, {
cwd: e2eCwd,
Expand Down
37 changes: 18 additions & 19 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,26 +25,25 @@
"prepare": "is-ci || husky install"
},
"devDependencies": {
"@angular-devkit/architect": "~0.1303.0",
"@angular-devkit/build-angular": "~13.3.0",
"@angular-devkit/build-optimizer": "~0.1302.0",
"@angular-devkit/build-webpack": "~0.1303.0",
"@angular-devkit/core": "~13.3.0",
"@angular-devkit/schematics": "~13.3.0",
"@angular-devkit/architect": "~0.1400.0-next.6",
"@angular-devkit/build-angular": "~14.0.0-next.6",
"@angular-devkit/build-webpack": "~0.1400.0-next.6",
"@angular-devkit/core": "~14.0.0-next.6",
"@angular-devkit/schematics": "~14.0.0-next.6",
"@angular-eslint/eslint-plugin": "~13.1.0",
"@angular-eslint/eslint-plugin-template": "~13.1.0",
"@angular-eslint/template-parser": "~13.1.0",
"@angular/cli": "~13.3.0",
"@angular/common": "~13.3.0",
"@angular/compiler": "~13.3.0",
"@angular/compiler-cli": "~13.3.0",
"@angular/core": "~13.3.0",
"@angular/forms": "~13.3.0",
"@angular/platform-browser": "~13.3.0",
"@angular/platform-browser-dynamic": "~13.3.0",
"@angular/router": "~13.3.0",
"@angular/service-worker": "~13.3.0",
"@angular/upgrade": "~13.3.0",
"@angular/cli": "~14.0.0-next.6",
"@angular/common": "~14.0.0-next.9",
"@angular/compiler": "~14.0.0-next.9",
"@angular/compiler-cli": "~14.0.0-next.9",
"@angular/core": "~14.0.0-next.9",
"@angular/forms": "~14.0.0-next.9",
"@angular/platform-browser": "~14.0.0-next.9",
"@angular/platform-browser-dynamic": "~14.0.0-next.9",
"@angular/router": "~14.0.0-next.9",
"@angular/service-worker": "~14.0.0-next.9",
"@angular/upgrade": "~14.0.0-next.9",
"@babel/helper-create-regexp-features-plugin": "^7.14.5",
"@cypress/webpack-preprocessor": "^5.9.1",
"@nestjs/common": "^8.0.0",
Expand Down Expand Up @@ -82,7 +81,7 @@
"@rollup/plugin-image": "^2.1.0",
"@rollup/plugin-json": "^4.1.0",
"@rollup/plugin-node-resolve": "^13.0.4",
"@schematics/angular": "~13.3.0",
"@schematics/angular": "~14.0.0-next.6",
"@storybook/addon-essentials": "~6.4.12",
"@storybook/addon-knobs": "~6.3.0",
"@storybook/angular": "~6.4.12",
Expand Down Expand Up @@ -189,7 +188,7 @@
"minimatch": "3.0.4",
"next": "12.1.0",
"next-sitemap": "^1.6.108",
"ng-packagr": "~13.3.0",
"ng-packagr": "~14.0.0-next.4",
"ngrx-store-freeze": "0.2.4",
"node-fetch": "^2.6.7",
"open": "^8.4.0",
Expand Down
85 changes: 85 additions & 0 deletions packages/angular/migrations.json
Original file line number Diff line number Diff line change
Expand Up @@ -1065,6 +1065,91 @@
"alwaysAddToPackageJson": false
}
}
},
"14.0.0": {
"version": "14.0.0-beta.0",
"packages": {
"@angular/cli": {
"version": "~14.0.0-next.6",
"alwaysAddToPackageJson": false
},
"@angular-devkit/build-angular": {
"version": "~14.0.0-next.6",
"alwaysAddToPackageJson": false
},
"@angular/core": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": true
},
"@angular/common": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/forms": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/elements": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/compiler": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/compiler-cli": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/localize": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/platform-browser": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/platform-browser-dynamic": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/platform-server": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/router": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/upgrade": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/language-service": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/animations": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/service-worker": {
"version": "~14.0.0-next.9",
"alwaysAddToPackageJson": false
},
"@angular/material": {
"version": "~14.0.0-next.8",
"alwaysAddToPackageJson": false
},
"@angular/cdk": {
"version": "~14.0.0-next.8",
"alwaysAddToPackageJson": false
},
"ng-packagr": {
"version": "~14.0.0-next.4",
"alwaysAddToPackageJson": false
}
}
}
}
}
4 changes: 2 additions & 2 deletions packages/angular/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,13 @@
"migrations": "./migrations.json"
},
"dependencies": {
"@angular-devkit/schematics": "~13.3.0",
"@angular-devkit/schematics": "~14.0.0-next.6",
"@nrwl/cypress": "*",
"@nrwl/devkit": "*",
"@nrwl/jest": "*",
"@nrwl/linter": "*",
"@nrwl/storybook": "*",
"@schematics/angular": "~13.3.0",
"@schematics/angular": "~14.0.0-next.6",
"@phenomnomnominal/tsquery": "4.1.1",
"ignore": "^5.0.4",
"jasmine-marbles": "~0.8.4",
Expand Down

0 comments on commit 228ccb2

Please sign in to comment.