nextui icon indicating copy to clipboard operation
nextui copied to clipboard

[BUG] Hydration failed because the initial UI does not match what was rendered on the server

Open ad-manish opened this issue 2 years ago • 3 comments

NextUI Version

2.2.6

Describe the bug

 return (
        <Card className="min-w-[400px]">
          <CardHeader className="flex gap-3">
            <Image
              alt="Algodomain logo"
              height={40}
              src="/LOGO.jpg"
              width={40}
            />
            <div className="flex flex-col"> Candidate Login</div>
          </CardHeader>
          <CardBody className="gap-3">
            <Input size="sm" type="email" label="Email" name="email" />
            <Input size="sm" type="password" label="Password" name="password" />
          </CardBody>
         </Card>
  );

Your Example Website or App

No response

Steps to Reproduce the Bug or Issue

When I am running the application npm run dev

on the port 3000 i am getting this error

This is related to the Input element in the card body, if I remove them, this error goes away.

Expected behavior

It should work

Screenshots or Videos

No response

Operating System Version

MacOS

Browser

Chrome

ad-manish avatar Nov 08 '23 10:11 ad-manish

Same issue here, only occurs with more then 1 input tho

NotLuksus avatar Nov 15 '23 16:11 NotLuksus

Disable the Chrome Extension like Dark Reader. it works 99% of the Time. Try that in Incognito Mode. And share the output of Console.

ghost avatar Nov 27 '23 13:11 ghost

A web extension was the problem for me, thanks! Unfortunately I have no solution except maybe using a (dynamically loaded) client component. And I guess it's not really possible for NextUI to handle this since it's a React issue.

mattiasw avatar Jan 27 '24 18:01 mattiasw