Loading
fix: remove unnecesary render caused by useMediaQuery hook
Changes
- Replaced all instances of
useMediaQuery(theme.breakpoints.down('md'));withuseIsMobile() - Replaced all instances of
useMediaQuery(theme.breakpoints.up('md'));withuseIsDesktop() - Add
{ noSsr: true }option in bothuseIsDesktop()anduseIsMobile()hooks. - Add
{ noSsr: true }option to all customuseMediaQueryhooks.
Important
I am aware that there are instances where we mix naming and actual query, like where we label "isMobile" query that is under sm.
We have to standardize this and name queries that don't fit custom desktop and mobile hooks differently, but this is out of the
ticket scope.
Closes #2139