Closed dstaley closed 6 months ago
Reproduction:
npx create-next-app@canary
(our app has next@14.3.0-canary.63
)import { MDXRemote } from 'next-mdx-remote/rsc';
export default function Notes() {
return (
<MDXRemote source="abc" />
);
}
In our app, we also have "react"
and "react-dom"
set to 18.3.1
in package.json
, but Next.js has its own compiled React version internally.
@karlhorky Thank you so much! The important detail there is having react@18.3.1
in package.json
. This issue does not reproduce if package.json
contains react@19.0.0-rc-915b914b3a-20240515
. I think there's some interaction between the v19 copy of React and the v18 copy that's causing this issue. I don't think we're going to have a stable release of either before v5, so this might need to be fixed once the dust settles because as it presents now I don't know if this is an actual issue or just a weird bug that's a result of mismatched React versions.
I just received confirmation from the Next.js team that Next 15 will require React 19. This error only occurs when Next 15 (which is what the canary will be) is used with React 18, so I'm going to go ahead and close this.