diff --git a/dusk.md b/dusk.md index ed3f8ffd52e..8ee6de005db 100644 --- a/dusk.md +++ b/dusk.md @@ -24,6 +24,7 @@ - [Scoping Selectors](#scoping-selectors) - [Waiting For Elements](#waiting-for-elements) - [Making Vue Assertions](#making-vue-assertions) + - [Scrolling An Element Into View](#scrolling-into-view) - [Available Assertions](#available-assertions) - [Pages](#pages) - [Generating Pages](#generating-pages) @@ -660,6 +661,14 @@ You may assert on the state of the Vue component like so: }); } + +### Scrolling An Element Into View + +The `scrollIntoView` method will scroll an element into view at the given selector. This is useful to call prior to interacting with an element that is not currently in view. + + $browser->scrollIntoView('selector') + ->click('selector'); + ## Available Assertions