Fixed JSX context-sensitive children discrimination for generic signatures#2803
Conversation
23d7c91 to
847b3fc
Compare
| >(props) => <div>{props.locale}</div> : (props: { locale: string; children: {}; }) => JSX.Element | ||
| >props : { locale: string; children: {}; } | ||
| >(props) => <div>{props.locale}</div> : (props: BaseProps) => JSX.Element | ||
| >props : BaseProps |
There was a problem hiding this comment.
this matched the explicit children prop variant below this. Strada also has a discrepancy: https://www.typescriptlang.org/play/?ts=6.0.0-dev.20260217#code/JYWwDg9gTgLgBAKjgQwM5wEoFNkGN4BmUEIcARFDvmQNwBQdMAnmFnAEJpYAKxY6AXjgBvOABsIuZGKwAuOKhhRgAOwDmcAL71GLNrwj8APABU4WAB4wsKgCbpOqHn1QA+OEOF04cXAAtgMVtKFXkACjAXeRMASg93bDwYADpE-AA5CFssek04ADI4Ex1s3DFkSjgCAFcVfGAIFTgAYRIwU3MrG3sOLgN+VwiouH7UU1cY+TSUgCkAZQANZIBRGRAbGB1cRsU4ACMweUdnQ0ERcUlpOXIbMi0tnfgsMQ84I1bwEWTvg81XYSGpziAncRlswAAbv9IqdkhIpDJNEYAPTgqFI5EfMCuejI5E+AmEonEwkAPQA-HRtipds8AEyvd5tL4-MB5fyBYI2AQAmH8YGgtHQlxwy6IlFCvLInF0PEk+UKxVwCl0IA
I think this is a clear improvement
There was a problem hiding this comment.
Ah, yes, the ObjectFlagsNonInferrableType flag wasn't being propagated. Nice!
There was a problem hiding this comment.
I would just leave Strada alone for now.
fixes #2802
fixes #2797