Skip to content
Merged
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion schemas/data.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,9 @@
},
"alternatives": {
"description": "IDs for features that substitute some or all of this feature's utility",
"items": {},
"items": {
"type": "string"
},
"type": "array"
}
},
Expand Down
6 changes: 5 additions & 1 deletion types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,11 @@ interface Discouraged {
/** Links to a formal discouragement notice, such as specification text, intent-to-unship, etc. */
according_to: string[];
/** IDs for features that substitute some or all of this feature's utility */
alternatives?: (keyof WebFeaturesData["features"])[];
alternatives?: string[];
// TODO: alternatives ought to be `(keyof WebFeaturesData["features"])[]`
// but ts-json-schema-generator seems to have long-standing unresolved bugs
// around this. Remove this when
// https://github.com/web-platform-dx/web-features/issues/2722 is resolved.
}

export interface GroupData {
Expand Down