3 ms·
Fully agree. I don't even see the use cases. For most things that are mentioned in the comments (mostly something like connecting proprietary USB devices to the
by Matthias247 11y ago
Fully agree. I don't even see the use cases. For most things that are mentioned in the comments (mostly something like connecting proprietary USB devices to the browser) a native application that proxies the related data to browsers seems like a much better approach. For well understood device classes that would be used by a bigger number of websites it makes far more sense to standardize high level APIs which covers exactly these devices (like it happened for webcam and other stuff).
The WebUSB approach also limits each device to be connected and controlled by exactly one browser frame which makes it not very desirable for sensor and other input applications.
- erikpukinskis 11y ago> a native application that proxies the related data to browsers seems like a much better approach Why do you think that? It seems needlessly complex to me when you could just have a simple permission pop up in the web app. What's the benefit of downloading an executable?
- Matthias247 11y agoAnd then you get the permission popup each time you open the page? Seems needlessly annoying to me. Or only once? Then most users would not have an idea on how to revoke the access right. Uninstalling the application they installed for the purpose seems more straightforward. Besides the permissions stuff giving a single browser window access to raw usb data seems also technically wrong. There are lots of reasons why we now have drivers instead of applications directly using the hardware like 30 years before. A driver or dedicated application can allow multiple clients (browser windows) to access the devices functionality. A driver directly embedded in a web page can't. A driver in the webpage even means that once you close that page the communication state between PC and USB device is in any state (can't see a way for automatically doing anything meaningful on goaway), so the only thing that could be done is disconnect and reconnect the device. So some further implications are: Multiple tabs for your web app are not possible. And even other stuff like Ctrl-R would not work as desired (disconnect device, reconnect device, wait, wait, wait, ...).