million icon indicating copy to clipboard operation
million copied to clipboard

Hydration failed - Next.js 14

Open drewbitt opened this issue 5 months ago • 18 comments

What version of million are you using?

3.0.6

Are you using an SSR adapter? If so, which one?

None

What package manager are you using?

npm

What operating system are you using?

Mac

What browser are you using?

Vivaldi (Chrome)

Describe the Bug

Info: Next.js 14.1.4, React 18.2.0 Node 18

const millionConfig = {
  auto: {
    rsc: true,
  },
};

I am getting a hydration error:

Unhandled Runtime Error
Error: Hydration failed because the initial UI does not match what was rendered on the server.

Warning: Did not expect server HTML to contain a <slot> in <slot>.

See more info here: https://nextjs.org/docs/messages/react-hydration-error

Component Stack
slot
MillionBlock
eval
ToastContextProvider
QueryClientProvider
SessionProvider
AppWrapper
MyApp

What's the expected result?

No errors. I do not have any slots in my code; this is all within Million itself and works without Million

This was not fixed with the previous report and fix in #977

Link to Minimal Reproducible Example

None - if I separate out the ToastContextProvider into a seperate app, I am not getting a reproduction, and as this is all within Million interacting with itself it is hard to do easily

Participation

  • [ ] I am willing to submit a pull request for this issue.

drewbitt avatar Mar 22 '24 18:03 drewbitt