Skip to content

The explaination is wrong in typescript guide #2895

Answered by devanshj
GuichiZhao asked this question in Bug report
Discussion options

You must be logged in to vote

Hi, I'm the author of the said documentation. Thanks for pointing out it's not because of invariance but because of the naive pattern matching TypeScript uses (as illustrated in the promise example too). Please go ahead and make a PR to improve the documentation.

Replies: 2 comments 10 replies

Comment options

You must be logged in to vote
6 replies
@dai-shi
Comment options

@GuichiZhao
Comment options

@dai-shi
Comment options

@GuichiZhao
Comment options

@dai-shi
Comment options

Comment options

You must be logged in to vote
4 replies
@GuichiZhao
Comment options

@dai-shi
Comment options

@GuichiZhao
Comment options

@dbritto-dev
Comment options

Answer selected by GuichiZhao
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
4 participants