From ba7ef23df11e4c34e222eb46829cbf252a7084d3 Mon Sep 17 00:00:00 2001 From: Alan Agius Date: Tue, 24 Nov 2020 20:36:13 +0100 Subject: [PATCH] docs: improve description for optimization, configuration and target options. Closes #16572 Closes #17978 Closes https://github.com/angular/angular/issues/39780 --- packages/angular/cli/commands/definitions.json | 2 +- packages/angular/cli/commands/deploy.json | 2 +- packages/angular/cli/commands/run.json | 2 +- packages/angular/cli/lib/config/schema.json | 16 ++++++++-------- .../build_angular/src/app-shell/schema.json | 4 ++-- .../build_angular/src/browser/schema.json | 2 +- .../build_angular/src/dev-server/schema.json | 4 ++-- .../build_angular/src/extract-i18n/schema.json | 2 +- .../build_angular/src/protractor/schema.json | 2 +- .../build_angular/src/server/schema.json | 2 +- 10 files changed, 19 insertions(+), 19 deletions(-) diff --git a/packages/angular/cli/commands/definitions.json b/packages/angular/cli/commands/definitions.json index 1713520fc1d1..489fcaf92994 100644 --- a/packages/angular/cli/commands/definitions.json +++ b/packages/angular/cli/commands/definitions.json @@ -14,7 +14,7 @@ } }, "configuration": { - "description": "A named build target, as specified in the \"configurations\" section of angular.json.\nEach named target is accompanied by a configuration of option defaults for that target.\nSetting this explicitly overrides the \"--prod\" flag", + "description": "One or more named builder configurations as a comma-separated list as specified in the \"configurations\" section of angular.json.\nThe builder uses the named configurations to run the given target.\nFor more information, see https://angular.io/guide/workspace-config#alternate-build-configurations.\nSetting this explicitly overrides the \"--prod\" flag", "type": "string", "aliases": [ "c" diff --git a/packages/angular/cli/commands/deploy.json b/packages/angular/cli/commands/deploy.json index 9bfc66786ca4..30e84ab4e0ac 100644 --- a/packages/angular/cli/commands/deploy.json +++ b/packages/angular/cli/commands/deploy.json @@ -20,7 +20,7 @@ } }, "configuration": { - "description": "A named build target, as specified in the \"configurations\" section of angular.json.\nEach named target is accompanied by a configuration of option defaults for that target.", + "description": "One or more named builder configurations as a comma-separated list as specified in the \"configurations\" section of angular.json.\nThe builder uses the named configurations to run the given target.\nFor more information, see https://angular.io/guide/workspace-config#alternate-build-configurations.", "type": "string", "aliases": [ "c" diff --git a/packages/angular/cli/commands/run.json b/packages/angular/cli/commands/run.json index 4111cc014a67..b6c3d64bb065 100644 --- a/packages/angular/cli/commands/run.json +++ b/packages/angular/cli/commands/run.json @@ -22,7 +22,7 @@ } }, "configuration": { - "description": "A named builder configuration, defined in the \"configurations\" section of angular.json.\nThe builder uses the named configuration to run the given target.", + "description": "One or more named builder configurations as a comma-separated list as specified in the \"configurations\" section of angular.json.\nThe builder uses the named configurations to run the given target.\nFor more information, see https://angular.io/guide/workspace-config#alternate-build-configurations.", "type": "string", "aliases": [ "c" ] } diff --git a/packages/angular/cli/lib/config/schema.json b/packages/angular/cli/lib/config/schema.json index 3adcd6420694..55751cdbf72b 100644 --- a/packages/angular/cli/lib/config/schema.json +++ b/packages/angular/cli/lib/config/schema.json @@ -633,11 +633,11 @@ "properties": { "browserTarget": { "type": "string", - "description": "Target to build." + "description": "A browser builder target to use for rendering the app shell in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`." }, "serverTarget": { "type": "string", - "description": "Server target to use for rendering the app shell." + "description": "A server builder target to use for rendering the app shell in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`." }, "appModuleBundle": { "type": "string", @@ -715,7 +715,7 @@ "additionalProperties": false }, "optimization": { - "description": "Enables optimization of the build output.", + "description": "Enables optimization of the build output. Including minification of scripts and styles, tree-shaking, dead-code eliminiation and fonts inlining. For more information, see https://angular.io/guide/workspace-config#optimization-and-source-map-configuration.", "oneOf": [ { "type": "object", @@ -1188,7 +1188,7 @@ "properties": { "browserTarget": { "type": "string", - "description": "Target to serve." + "description": "A browser builder target to serve in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`." }, "port": { "type": "number", @@ -1280,7 +1280,7 @@ "default": true }, "optimization": { - "description": "Enable optimization of the build output.", + "description": "Enables optimization of the build output. Including minification of scripts and styles, tree-shaking, dead-code eliminiation and fonts inlining. For more information, see https://angular.io/guide/workspace-config#optimization-and-source-map-configuration.", "default": false, "oneOf": [ { @@ -1371,7 +1371,7 @@ "properties": { "browserTarget": { "type": "string", - "description": "Target to extract from." + "description": "A browser builder target to extract i18n messages in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`." }, "format": { "type": "string", @@ -1689,7 +1689,7 @@ }, "devServerTarget": { "type": "string", - "description": "Dev server target to run tests against." + "description": "A dev-server builder target to run tests against in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`." }, "grep": { "type": "string", @@ -1767,7 +1767,7 @@ "additionalProperties": false }, "optimization": { - "description": "Enables optimization of the build output.", + "description": "Enables optimization of the build output. Including minification of scripts and styles, tree-shaking and dead-code eliminiation. For more information, see https://angular.io/guide/workspace-config#optimization-and-source-map-configuration.", "default": false, "oneOf": [ { diff --git a/packages/angular_devkit/build_angular/src/app-shell/schema.json b/packages/angular_devkit/build_angular/src/app-shell/schema.json index b89b795265ab..3adcc32a7521 100644 --- a/packages/angular_devkit/build_angular/src/app-shell/schema.json +++ b/packages/angular_devkit/build_angular/src/app-shell/schema.json @@ -6,12 +6,12 @@ "properties": { "browserTarget": { "type": "string", - "description": "Target to build.", + "description": "A browser builder target use for rendering the app shell in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`.", "pattern": "^[^:\\s]+:[^:\\s]+(:[^\\s]+)?$" }, "serverTarget": { "type": "string", - "description": "Server target to use for rendering the app shell.", + "description": "A server builder target use for rendering the app shell in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`.", "pattern": "^[^:\\s]+:[^:\\s]+(:[^\\s]+)?$" }, "appModuleBundle": { diff --git a/packages/angular_devkit/build_angular/src/browser/schema.json b/packages/angular_devkit/build_angular/src/browser/schema.json index 58605af68b24..4b6d4ad74322 100644 --- a/packages/angular_devkit/build_angular/src/browser/schema.json +++ b/packages/angular_devkit/build_angular/src/browser/schema.json @@ -57,7 +57,7 @@ "additionalProperties": false }, "optimization": { - "description": "Enables optimization of the build output.", + "description": "Enables optimization of the build output. Including minification of scripts and styles, tree-shaking, dead-code eliminiation and fonts inlining. For more information, see https://angular.io/guide/workspace-config#optimization-and-source-map-configuration.", "x-user-analytics": 16, "default": false, "oneOf": [ diff --git a/packages/angular_devkit/build_angular/src/dev-server/schema.json b/packages/angular_devkit/build_angular/src/dev-server/schema.json index 2c2c0bf15279..e84dcddb7965 100644 --- a/packages/angular_devkit/build_angular/src/dev-server/schema.json +++ b/packages/angular_devkit/build_angular/src/dev-server/schema.json @@ -6,7 +6,7 @@ "properties": { "browserTarget": { "type": "string", - "description": "Target to serve.", + "description": "A browser builder target to serve in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`.", "pattern": "^[^:\\s]+:[^:\\s]+(:[^\\s]+)?$" }, "port": { @@ -105,7 +105,7 @@ "x-deprecated": "No longer has an effect." }, "optimization": { - "description": "Enables optimization of the build output.", + "description": "Enables optimization of the build output. Including minification of scripts and styles, tree-shaking, dead-code eliminiation, tree-shaking and fonts inlining. For more information, see https://angular.io/guide/workspace-config#optimization-and-source-map-configuration.", "x-user-analytics": 16, "oneOf": [ { diff --git a/packages/angular_devkit/build_angular/src/extract-i18n/schema.json b/packages/angular_devkit/build_angular/src/extract-i18n/schema.json index 5beb6e262b0b..3d08debc2cb0 100644 --- a/packages/angular_devkit/build_angular/src/extract-i18n/schema.json +++ b/packages/angular_devkit/build_angular/src/extract-i18n/schema.json @@ -6,7 +6,7 @@ "properties": { "browserTarget": { "type": "string", - "description": "Target to extract from.", + "description": "A browser builder target to extract i18n messages in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`.", "pattern": "^[^:\\s]+:[^:\\s]+(:[^\\s]+)?$" }, "format": { diff --git a/packages/angular_devkit/build_angular/src/protractor/schema.json b/packages/angular_devkit/build_angular/src/protractor/schema.json index c4fd14eff06a..ff431254bdfe 100644 --- a/packages/angular_devkit/build_angular/src/protractor/schema.json +++ b/packages/angular_devkit/build_angular/src/protractor/schema.json @@ -10,7 +10,7 @@ }, "devServerTarget": { "type": "string", - "description": "Dev server target to run tests against.", + "description": "A dev-server builder target to run tests against in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`.", "pattern": "^([^:\\s]+:[^:\\s]+(:[^\\s]+)?)?$" }, "grep": { diff --git a/packages/angular_devkit/build_angular/src/server/schema.json b/packages/angular_devkit/build_angular/src/server/schema.json index 37156ab41d92..fa84f670c67a 100644 --- a/packages/angular_devkit/build_angular/src/server/schema.json +++ b/packages/angular_devkit/build_angular/src/server/schema.json @@ -29,7 +29,7 @@ "additionalProperties": false }, "optimization": { - "description": "Enables optimization of the build output.", + "description": "Enables optimization of the build output. Including minification of scripts and styles, tree-shaking and dead-code eliminiation. For more information, see https://angular.io/guide/workspace-config#optimization-and-source-map-configuration.", "x-user-analytics": 16, "default": false, "oneOf": [