Vuetify

ショップ

企業向け

v-scrollディレクティブによって、ウィンドウや特定の要素がスクロールされた際のコールバック関数を設定することができます。

デフォルトではウィンドウにバインドされます。追加の設定が必要ない場合は、単純にコールバック関数を渡すことができます。

確認したいコンポーネントを下から選び、利用できる props、slots、events、functions を確認してください。

以下に、簡単な例から複雑な例まで示します。

指定した要素にイベントリスナーをバインドすることもできます。

v-scroll targets the window by default but can also watch the element it's being bound to. In the following example we use the self modifier, v-scroll.self, to watch the v-card element specifically. This causes the method onScroll to invoke as you scroll the card contents; incrementing the counter.

New in v2.3

準備はいいですか? 以下から続きが読めます。

Caught a mistake or want to contribute to the documentation? Edit Layout on GitHub!