refactor(@angular/cli): provide default serve target for applications#28011
Draft
clydin wants to merge 3 commits intoangular:mainfrom
Draft
refactor(@angular/cli): provide default serve target for applications#28011clydin wants to merge 3 commits intoangular:mainfrom
clydin wants to merge 3 commits intoangular:mainfrom
Conversation
b63e0df to
7701ee6
Compare
|
What about this PR? It's cool, and i hope it will be released with 19 :( |
The `serve` command will now use a default project target and builder name if the target entry is not explicitly defined. This allows the removal of additional configuration from an `angular.json` file. If the target is already present than it will take priority over any default builder behavior. The default logic will use the appropriate development server builder for officially supported packages (`@angular/build`/`@angular-devkit/build-angular`). The `dev-server` builder from these packages will currently assume a `development` configuration is present within the `build` target. The default behavior may be expanded in the future to support more arbitrary `build` target configurations. If there is third-party package usage within the `build` target, the CLI will attempt to discover a `dev-server` builder within the same package used by the `build` target. If none is found, no default will be added and the `serve` command will issue an error when no explicit target is present.
…on to be optional The development server (`dev-server`) within `@angular/build` no longer requires a `buildTarget` option to be specified. If not present, the value will default to the current project's 'build' target. The configuration used for the build target will be the same as the development server configuration if specified or, if not specified, it will default to `development`.
…ildTarget` option to be optional The development server (`dev-server`) within `@angular-devkit/build-angular` no longer requires a `buildTarget` option to be specified. If not present, the value will default to the current project's 'build' target. The configuration used for the build target will be the same as the development server configuration if specified or, if not specified, it will default to `development`.
c677e26 to
7c48870
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
servecommand will now use a default project target and builder name if the target entry is not explicitly defined. This allows the removal of additional configuration from anangular.jsonfile. If the target is already present than it will take priority over any default builder behavior. The default logic will use the appropriate development server builder for officially supported packages (@angular/build/@angular-devkit/build-angular). Thedev-serverbuilder from these packages will currently assume adevelopmentconfiguration is present within thebuildtarget. The default behavior may be expanded in the future to support more arbitrarybuildtarget configurations. If there is third-party package usage within thebuildtarget, the CLI will attempt to discover adev-serverbuilder within the same package used by thebuildtarget. If none is found, no default will be added and theservecommand will issue an error when no explicit target is present.