Skip to content

Pass contextFlags when getting contextual type of JSX elements/attributes - #49707

Merged
Jake Bailey (jakebailey) merged 3 commits into
microsoft:mainfrom
jakebailey:fix-44596
Jun 28, 2022
Merged

Jake Bailey (jakebailey) merged 3 commits into
microsoft:mainfrom
jakebailey:fix-44596

Conversation

@jakebailey

@jakebailey Jake Bailey (jakebailey) commented Jun 28, 2022 •

Copy link
Copy Markdown
Member

Fixes #44596

The context flags were not being passed through when working with JSX elements/attributes, which meant that instantiateContextualType didn't use the inferences to instantiate the signature.

I think it'd be best if the contextFlags parameter were required, and I have a change that does so (we don't pass flags in a few more places, likely also unintentionally), but doing so doesn't seem to reveal any baseline changes. I was hoping that #45596 could be fixed as a result, but just fixing up the flag plumbing doesn't seem to help.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Author: Team For Milestone Bug PRs that fix a bug with a specific milestone

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Arguments to callback prop of generic React component are not inferred

3 participants