Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions packages/angular/cli/lib/config/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -327,12 +327,40 @@
"additionalProperties": {
"$ref": "#/definitions/project/definitions/target"
}
},
"targets": {
"type": "object",
"additionalProperties": {
"$ref": "#/definitions/project/definitions/target"
}
}
},
"required": [
"root",
"projectType"
],
"anyOf": [
{
"required": ["architect"],
"not": {
"required": ["targets"]
}
},
{
"required": ["targets"],
"not": {
"required": ["architect"]
}
},
{
Copy link
Copy Markdown
Collaborator Author

@alan-agius4 alan-agius4 Sep 8, 2018

Choose a reason for hiding this comment

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

This is because targets and architect are not really required. If they were it could have been something like

"oneOf": [
        {
            "required": ["targets"]
         },
        {
            "required": ["architect"]
        }
]

"not": {
"required": [
"targets",
"architect"
]
}
}
],
"additionalProperties": false,
"patternProperties": {
"^[a-z]{1,3}-.*": {}
Expand Down