• ユーザーのデバイスのディスプレイに関する情報を参照可能なロジックを生成します。

    VuetifyのuseDisplayコンポーザブルをラップした関数です。

    Returns {
        height: Ref<number>;
        lg: Ref<boolean>;
        lgAndDown: Ref<boolean>;
        lgAndUp: Ref<boolean>;
        md: Ref<boolean>;
        mdAndDown: Ref<boolean>;
        mdAndUp: Ref<boolean>;
        mobile: ComputedRef<boolean>;
        mobileBreakpoint: Ref<number | DisplayBreakpoint>;
        name: Ref<DisplayBreakpoint>;
        platform: Ref<DisplayPlatform>;
        sm: Ref<boolean>;
        smAndDown: Ref<boolean>;
        smAndUp: Ref<boolean>;
        thresholds: Ref<DisplayThresholds>;
        width: Ref<number>;
        xl: Ref<boolean>;
        xlAndDown: Ref<boolean>;
        xlAndUp: Ref<boolean>;
        xs: Ref<boolean>;
        xxl: Ref<boolean>;
    }

    • height: Ref<number>
    • lg: Ref<boolean>
    • lgAndDown: Ref<boolean>
    • lgAndUp: Ref<boolean>
    • md: Ref<boolean>
    • mdAndDown: Ref<boolean>
    • mdAndUp: Ref<boolean>
    • mobile: ComputedRef<boolean>
    • mobileBreakpoint: Ref<number | DisplayBreakpoint>
    • name: Ref<DisplayBreakpoint>
    • platform: Ref<DisplayPlatform>
    • sm: Ref<boolean>
    • smAndDown: Ref<boolean>
    • smAndUp: Ref<boolean>
    • thresholds: Ref<DisplayThresholds>
    • width: Ref<number>
    • xl: Ref<boolean>
    • xlAndDown: Ref<boolean>
    • xlAndUp: Ref<boolean>
    • xs: Ref<boolean>
    • xxl: Ref<boolean>

    See

    Vuetify - useDisplay

    Example

    const { mobile } = Mdc.useMdcDisplay();
    // 現在のユーザーのデバイスがモバイルか否かを示します
    console.log(mobile)