Hiyve Components - v1.0.0
    Preparing search index...

    Return type for the useContainerBreakpoint hook.

    const { isBelowBreakpoint, containerRef } = useContainerBreakpoint(700);

    return (
    <div ref={containerRef}>
    {isBelowBreakpoint ? <MobileLayout /> : <DesktopLayout />}
    </div>
    );
    interface UseContainerBreakpointResult {
        containerRef: RefObject<HTMLElement>;
        isBelowBreakpoint: boolean;
    }
    Index

    Properties

    containerRef: RefObject<HTMLElement>

    Ref to attach to the container element.

    isBelowBreakpoint: boolean

    Whether the container width is below the breakpoint.