Skip to content

Conversation

@DiegoAndai
Copy link
Member

@DiegoAndai DiegoAndai commented May 22, 2024

Based on #42032
First step towards #42032

Summary

This PR includes the type changes we can implement without upgrading to the new @types/ packages (which is a WIP). It's achieved by:

  • Running npx types-react-codemod@latest preset-19 but skipping the useRef-required-initial codemod (See missing section below)
  • Running npx types-react-codemod@latest react-element-default-any-props to maintain ReactElement's previous default.

This results in the following changes:

Missing

The following are missing, to be implemented after DefinitelyTyped/DefinitelyTyped#69022 is merged:

@DiegoAndai DiegoAndai added typescript internal Behind-the-scenes enhancement. Formerly called “core”. labels May 22, 2024
@DiegoAndai DiegoAndai self-assigned this May 22, 2024
@mui-bot
Copy link

mui-bot commented May 22, 2024

Netlify deploy preview

https://deploy-preview-42346--material-ui.netlify.app/

Bundle size report

No bundle size changes (Toolpad)
No bundle size changes

Generated by 🚫 dangerJS against c8b83ae

@DiegoAndai DiegoAndai changed the title [core] WIP React 19 types [core] Apply React 19 type changes that don't require upcoming @types/ packages May 23, 2024
@DiegoAndai DiegoAndai requested a review from michaldudak May 23, 2024 16:11
@DiegoAndai DiegoAndai marked this pull request as ready for review May 23, 2024 16:11
Copy link
Member

@michaldudak michaldudak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't check all the files but the changes make sense. I agree that we should progressively improve the ReactElement situation.

@DiegoAndai DiegoAndai merged commit 78d723b into mui:next May 24, 2024
@DiegoAndai DiegoAndai deleted the react-19-types branch May 24, 2024 16:11
@DiegoAndai DiegoAndai added the integration: react About improving React support. label Jul 2, 2024
joserodolfofreitas pushed a commit to joserodolfofreitas/material-ui that referenced this pull request Jul 29, 2024
DiegoAndai added a commit to DiegoAndai/material-ui that referenced this pull request Nov 19, 2024
DiegoAndai added a commit that referenced this pull request Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

integration: react About improving React support. internal Behind-the-scenes enhancement. Formerly called “core”. typescript

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants