4 Commits

Author SHA1 Message Date
Alan Agius
4b0223b64e build: automate @angular/cli schema.json generation
With this change we automate the generation of `@angular/cli/lib/config/schema.json`. While on paper we could use quicktype for this. Quicktype doesn't handle `patternProperties` and `oneOf` that well.

How does this works?
Relative `$ref` will be resolved and inlined as part of the root schema definitions.

Example
```json
"@schematics/angular:enum": {
    "$ref": "../../../../schematics/angular/enum/schema.json"
},
```

Will be parsed and transformed to
```json
"@schematics/angular:enum": {
  "$ref": "#/definitions/SchematicsAngularEnumSchema"
},
"definitions: {
  "SchematicsAngularEnumSchema": {
    "title": "Angular Enum Options Schema",
    "type": "object",
    "description": "Generates a new, generic enum definition for the given or default project.",
    "properties": {...}
   }
}
```
2021-03-11 21:51:37 +01:00
Charles Lyding
fda683b874 build: only generate types for actual JSON schemas 2019-04-11 10:17:29 -07:00
Hans Larsen
32a32d69ef build: delete the dist-schema/ before generating it 2019-03-19 10:07:46 -07:00
Hans Larsen
b3857b41a4 build: add build-schema script to build schemas 2019-02-21 16:20:54 -08:00