ealfonso
ealfonso

Reputation: 7312

Intercept navigator.usb.requestDevice dialog with puppeteer

Is it possible to intercept the dialog created after requesting a usb device via navigator.usb.requestDevice? I tried page.on("dialog", dialog => () from the puppeteer script and document.addEventListener('dialog', () => ...) from the page DOM but none of those callbacks were invoked.

Dialog

Upvotes: 2

Views: 161

Answers (1)

Reilly Grant
Reilly Grant

Reputation: 6093

This is not possible today but it is something the Chromium project is aware developers are interested in.

To help prioritize this feature, can you say what your use case for automating this dialog is?

Upvotes: 2

Related Questions