[docs] Fix peer dependency range#15281
Conversation
|
Deploy preview: https://deploy-preview-15281--material-ui-x.netlify.app/ |
|
Hi! This means that we cant' use mui-x with Next.js 15? |
eefde14 to
2fac339
Compare
|
@LukasTy Ah right, I forgot #13356. Proposing this for the next company product meeting https://www.notion.so/mui-org/product-Company-Product-Meeting-2024-11-18-135cbfe7b66080518203cff028b28579?pvs=4#135cbfe7b660810eba5ed10342dac778.
@leonardolombardi07 You should be able ot install Can people use MUI X with Next.js 15 today? Yeah, kind of. I have just tried and didn't see any obvious problems. But until we run all the tests with React 19, we have to fix bugs as people report them, we are a bit blind. |
I upgraded from next 14 to 15 using their codemods script.. and it throws a bunch of peer dependency errors from mui-x-data-grid..I can obviously override them (probably) or just ignore. NextJs15 requires react 19 and mui data grid allows 18, its spits errors like below (and also about react_dom 19) @mui/x-data-grid@"^7.22.1" from the root project |
|
@marketsystems Right, this makes sense. It's about #13356. For now, you can force the conflict of peer dependencies. |
|
@oliviertassinari @marketsystems |
|
@LukasTy This should be clearer: https://x.com/olivtassinari/status/1849418686962061769 |
forcing peer dependencies did work for me i still got a bunch of errors from all different packages but I just added to the overrides nextjs has already hacked into the package.json and copied in react and react dom versions it had installed: Its not great but it appears to work temporarily. Really depends I guess how long until react 19 actually has a proper stable version!! "overrides": { |
yep was about to reply same, page router can be compatible but app router not.. Personally I dont see why anybody should be making new projects with pages router, understandably some may have old projects with pages router though |
@oliviertassinari Ok, thanks for the clarification, I assumed something similar. 👌 |
I noticed this in https://www.npmjs.com/package/@mui/x-charts, it's a turn-off for adopting the lib. This was forgotten in #14142.
Off-topic. we might miss React 19 here in the peer dependency, needed to use Next.js 15.