UNPKG

@bianic-ui/media-query

Version:

A React hook for changing properties or visibility of a component based on css media query

16 lines (15 loc) 511 B
export interface Breakpoint { breakpoint: string; maxWidth?: string; minWidth: string; } /** * React hook used to get the current responsive media breakpoint. * * @param defaultBreakpoint default breakpoint name * (in non-window environments like SSR) * * For SSR, you can use a package like [is-mobile](https://github.com/kaimallea/isMobile) * to get the default breakpoint value from the user-agent */ export declare function useBreakpoint(defaultBreakpoint?: string): string | undefined;