mui / material-ui

Material UI: Comprehensive React component library that implements Google's Material Design. Free forever.
https://mui.com/material-ui/
MIT License
94.02k stars 32.3k forks source link

[Grid2] codemod migrating to Grid2 not working #44497

Closed shifoc closed 16 hours ago

shifoc commented 19 hours ago

Steps to reproduce

I am migrating from Grid to Grid2

I changed the imports: -import Grid from '@mui/material/Grid'; +import Grid from '@mui/material/Grid2';

and Run the codemod: npx @mui/codemod@latest v6.0.0/grid-v2-props <path/to/folder>

it did not change anything

Current behavior

No response

Expected behavior

No response

Context

No response

Your environment

System: OS: Windows 10 10.0.19045 Binaries: Node: 18.18.0 - C:\Program Files\nodejs\node.EXE npm: 9.8.1 - C:\Program Files\nodejs\npm.CMD pnpm: Not Found Browsers: Chrome: Not Found Edge: Chromium (127.0.2651.74)

Search keywords: Grid Grid2

shifoc commented 18 hours ago

EDIT: After trying again multiple times it worked but it's always adding unnecessary parenthesis

sai6855 commented 17 hours ago

@shifoc Can you share git repo or minimal example to reproduce your issue?

DiegoAndai commented 16 hours ago

Thanks for the report @shifoc, and I'm glad that it worked.

it's always adding unnecessary parenthesis

We recommend running your code formatter after running the codemods, for example, running prettier if that's what you use. This is because we don't know each user's formatting settings and/or tools, so we cannot fix it on our side.

github-actions[bot] commented 16 hours ago

This issue has been closed. If you have a similar problem but not exactly the same, please open a new issue. Now, if you have additional information related to this issue or things that could help future readers, feel free to leave a comment.

[!NOTE] @shifoc How did we do? Your experience with our support team matters to us. If you have a moment, please share your thoughts in this short Support Satisfaction survey.