brother-ql / web/src / requestPrinters
Function: requestPrinters()
requestPrinters(
opts):Promise<Readonly<Record<string,PrinterAdapter>>>
Unified browser-picker factory for the brother-ql driver family.
Dispatches on opts.transport:
'usb'— opensnavigator.usbpicker. Auto-identifies viausbDevice.vendorId/productIdagainst the registry. ThrowsDeviceIdentificationRequiredErroronly if the picked device's VID/PID is not in the brother-ql registry.'bluetooth-spp'— always-ask (Web Serial has no BT name surface).opts.deviceKeyrequired; if omitted, throwsDeviceIdentificationRequiredErrorwith the BT-SPP-capable subset ofDEVICES(e.g. QL_820NWBc, PT_P910BT).continueWith(deviceKey)opens the Web Serial picker for the chosen device.'serial'— not declared in the brother-ql registry today; throws unconditionally.'bluetooth-gatt'— not declared in the brother-ql registry today; throws unconditionally.
Returns a 1-key PrinterAdapterMap keyed by the device's primary engine role.
Parameters
opts
Returns
Promise<Readonly<Record<string, PrinterAdapter>>>