forked from Archives/Athou_commafeed
8 lines
291 B
TypeScript
8 lines
291 B
TypeScript
import { useMediaQuery } from "@mantine/hooks"
|
|
import { Constants } from "app/constants"
|
|
|
|
export const useMobile = (breakpoint: string = Constants.layout.mobileBreakpoint) =>
|
|
!useMediaQuery(`(min-width: ${breakpoint})`, undefined, {
|
|
getInitialValueInEffect: false,
|
|
})
|