playwright-fluent
Version:
Fluent API around playwright
15 lines (14 loc) • 425 B
JavaScript
Object.defineProperty(exports, "__esModule", { value: true });
exports.scrollToHandle = void 0;
async function scrollToHandle(selector) {
if (!selector) {
return;
}
await selector.evaluate((el) => {
if (el && typeof el.scrollIntoView === 'function') {
el.scrollIntoView({ block: 'center', inline: 'center' });
}
});
}
exports.scrollToHandle = scrollToHandle;
;