I recently learned that the TS type-checker is unsound on purpose and i am a bit disappointed.<p><a href="http:&#x2F;&#x2F;tryflow.org&#x2F;#2944d91c10fc5d76faeebbb20cac466a" rel="nofollow">http:&#x2F;&#x2F;tryflow.org&#x2F;#2944d91c10fc5d76faeebbb20cac466a</a> Try this snippet in TS.