Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: useMediaQuery is a client-only hook #326

Open
yeasin2002 opened this issue Dec 31, 2024 · 1 comment
Open

Error: useMediaQuery is a client-only hook #326

yeasin2002 opened this issue Dec 31, 2024 · 1 comment

Comments

@yeasin2002
Copy link

I'm using useMediaQuery hook from @uidotdev/usehooks. My parent component is a client component then this error also occurs.

⨯ Error: useMediaQuery is a client-only hook
at DashboardLayout (./src/app/dashboard/page.tsx:35:92)
digest: "2779910239"

@DohnalMichal
Copy link

There is an existing workaround. See #218 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants