ElementHandle.scrollIntoView() 方法
🌐 ElementHandle.scrollIntoView() method
使用自动化协议客户端或通过调用 element.scrollIntoView 将元素滚动到视图中。
🌐 Scrolls the element into view using either the automation protocol client or by calling element.scrollIntoView.
语法
🌐 Signature
class ElementHandle {
scrollIntoView(this: ElementHandle<Element>): Promise<void>;
}
参数
🌐 Parameters
范围 🌐 Parameter | 类型 🌐 Type | 描述 🌐 Description |
|---|---|---|
this | ElementHandle<Element> |
返回:
Promise<void>