Skip to content

Improve first Example of "The satisfies Operator" in TS 4.9 r notes - #3050

Merged
Jake Bailey (jakebailey) merged 1 commit into
microsoft:v2from
mariusgau:v2
Jun 5, 2024
Merged

Improve first Example of "The satisfies Operator" in TS 4.9 r notes#3050
Jake Bailey (jakebailey) merged 1 commit into
microsoft:v2from
mariusgau:v2

Conversation

@mariusgau

@mariusgau Marius (mariusgau) commented Mar 27, 2024

Copy link
Copy Markdown
Contributor

See for details: microsoft/TypeScript#57005

tl;dr: Documentation is incorrect or misleading. Since values are unions of string and array, palette.red.at(0) will not throw an error, because at() method is a method that exists for both types.

@mariusgau Marius (mariusgau) changed the title Improve first Example of "The satisfies Operator" in TypeScript 4.9 r… Improve first Example of "The satisfies Operator" in TS 4.9 r notes Mar 27, 2024
@mariusgau
Marius (mariusgau) marked this pull request as ready for review March 27, 2024 18:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants