BeanstalkFarms/Beanstalk

UI: Switch to `useMediaQuery` or CSS approach for mobile window check

Closed this issue · 0 comments

Future work: Switch this to the useMediaQuery API which optimizes event listeners. This implementation works but will be slow, especially when the user is dragging their screen size to be smaller.

https://mui.com/material-ui/react-use-media-query/

Alternatively, the JS-based style strategy could be replaced with a CSS-based one where a new component is rendered after a certain breakpoint.

Originally posted by @silochad in #367 (comment)