Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Currently, the
undefined
keyword is used to represent thenever
type in provided TypeScript code. This is undesirable, as it can lead to some situations where the intended use of the keyword is ambiguous. Fortunately, #1154 added aNeverType
, although it is only used marginally in the current version. As I previously mentioned in #1261, gradually switching toNeverType
is hard, as it leads to regressions. Therefore, this pr aims to replace all affected occurrences of theundefined
keyword withNeverType
. Additionally, optional object properties with typenever
are now hidden by theObjectTypeFormatter
whenadditionalProperties
isfalse
.