Skip to content
This repository has been archived by the owner on Apr 9, 2022. It is now read-only.

fix(@angular-devkit/build-angular): support some browser options in dev-server #734

Merged
merged 1 commit into from
Apr 18, 2018

Conversation

hansl
Copy link
Contributor

@hansl hansl commented Apr 18, 2018

This will allow people to override some flags from a base browser target, either from
the command line or from their serve directly.

The options chosen are kinda arbitrary. I simply looked at what made sense.

Fix angular/angular-cli#10304

@hansl hansl requested a review from filipesilva April 18, 2018 15:49
@hansl hansl added this to the v6.0.0 milestone Apr 18, 2018
clydin
clydin previously approved these changes Apr 18, 2018
Copy link
Member

@clydin clydin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It'd be nice long-term if this type of functionality could be supported without the repetition of options.

"optimization": {
"type": "boolean",
"description": "Defines the optimization level of the build.",
"default": false
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These options cannot have a default, otherwise the default will always override the browser target values.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

@hansl
Copy link
Contributor Author

hansl commented Apr 18, 2018

It'd be nice long-term if this type of functionality could be supported without the repetition of options.

Yes, and that's what my other PR that I got carried away with is about; enabling us to walk the schema properly to discover options. Let's not get distracted for 6.0 though and implement allOf and anyOf and those kind of things in 6.1. This PR is the bandaid we need for 6.0.

@hansl hansl force-pushed the fix-10304 branch 2 times, most recently from d7b599a to 3957323 Compare April 18, 2018 17:41
Copy link
Contributor

@filipesilva filipesilva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just that last point and it LGTM.

@@ -51,6 +51,15 @@ export interface DevServerBuilderOptions {
watch: boolean;
hmrWarning: boolean;
servePathDefaultWarning: boolean;

optimization: boolean;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are all optional now.

…ev-server

This will allow people to override some flags from a base browser target, either from
the command line or from their serve directly.

The options chosen are kinda arbitrary. I simply looked at what made sense.

Fix angular/angular-cli#10304
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants