chore(table): support for typescript 2.7.x #10479
Closed
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.
I'm honestly opening this PR because I don't understand this particular error and it's occurring in my codebase as well. Looks like ternary statements are being type checked now and the way the types resolve appears to be an issue. I've tried a similar reproduction of the types and it seems that the way a ternary resolves for a generic is
T<A> | T<B>
(assuming the same base class with generic) instead ofT<A | B>
. Maybe this is a typescript orrxjs issue(or both)?EDIT: This issue is present with rxjs 5.5.x+ and typescript 2.7.x
This is my simple reproduction:

Before:

After:

Seems that because of the type ambiguity, the resolution for the
pipe
method is thepipe
with no arguments.