The Scandit license key to be used by the library.
If enabled, any BarcodePicker or Scanner object will be able to start processing video frames much faster, as it won't need to generate blurry recognition data lazily only when needed. If necessary, depending on given ScanSettings options and on readiness of the data, processing is also initially performed without blurry recognition until this data becomes available, at which point the new data will be loaded and used.
If disabled, BarcodePicker or Scanner objects will load or generate blurry recognition data lazily when needed to process the first frame, depending on given ScanSettings options, and will thus require more time the first time the library is actively used with the given active symbologies. As this needs to be done in the same WebWorker, the processing of the frame will then be blocked until the needed data is loaded or generated.
Note that in either case the data for blurry recognition will be cached for later successive uses of the library.
Note that preloading does not trigger a device activation for licensing purposes.
If enabled, any BarcodePicker or Scanner object will be ready to start processing video frames much faster, as the needed external Scandit Engine library will already be in a partially or fully initialized state thanks to it being preloaded now.
If disabled, BarcodePicker and Scanner objects will load the external Scandit Engine library on creation (if it wasn't already loaded before by a previously created object), and will thus require more time to be initialized and ready.
Note that in either case the loaded external Scandit Engine library will be reused whenever possible for later successive uses of the library.
Note that preloading does not trigger a device activation for licensing purposes.
A promise resolving when the library has been configured (preloading is done independently asynchronously).
Generated using TypeDoc
Initialize and configure the Scandit Barcode Scanner SDK library. This function must be called as first thing before using any other function of the library.
Depending on parameters and device features, any of the following errors could be the rejected result of the returned promise:
NoLicenseKeyError
UnsupportedBrowserError
The external external Scandit Engine library and data needed for blurry recognition are preloaded asynchronously eagerly by default after library configuration to ensure the best performance. If needed this behaviour can be changed via the preloadEngine and preloadBlurryRecognition options.
Camera access requests are done lazily only when needed by a BarcodePicker (or Scanner) object. You can also eagerly ask only for camera access permissions by calling the CameraAccess.getCameras function.
Ideally, to make the scanning process faster, it is recommended depending on the use case to create in advance a (hidden and paused) BarcodePicker or Scanner object, to later show and unpause it when needed. Depending on the options this can also be used to correctly ask for camera access permissions whenever preferred.