Last active
October 2, 2025 06:57
-
-
Save thewisenerd/fe86396414b84f9de92524536f3c5e86 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { type MantineBreakpoint, useMantineTheme } from '@mantine/core' | |
| export const useMinWidth = (breakpoint: MantineBreakpoint) => { | |
| const theme = useMantineTheme() | |
| const media = window.matchMedia( | |
| `(min-width: ${theme.breakpoints[breakpoint]})` | |
| ) | |
| return media.matches | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment