How to use the expo-barcode-scanner.BarCodeScanner.scanFromURLAsync function in expo-barcode-scanner

To help you get started, we’ve selected a few expo-barcode-scanner examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github flow-typed / flow-typed / definitions / npm / expo-barcode-scanner_v5.x.x / flow_v0.104.x- / test_expo-barcode-scanner.js View on Github external
it('should raises an error when call with invalid args', () => {
      // $ExpectError: first argument is required
      BarCodeScanner.scanFromURLAsync();

      // $ExpectError: first argument must be a string
      BarCodeScanner.scanFromURLAsync(123);

      // $ExpectError: second argument must be an array
      BarCodeScanner.scanFromURLAsync('url', 123);

      BarCodeScanner.scanFromURLAsync('url', [
        // $ExpectError: invalid barcode type
        123,
      ]);
    });
  });
github flow-typed / flow-typed / definitions / npm / expo-barcode-scanner_v5.x.x / flow_v0.104.x- / test_expo-barcode-scanner.js View on Github external
it('should raises an error when call with invalid args', () => {
      // $ExpectError: first argument is required
      BarCodeScanner.scanFromURLAsync();

      // $ExpectError: first argument must be a string
      BarCodeScanner.scanFromURLAsync(123);

      // $ExpectError: second argument must be an array
      BarCodeScanner.scanFromURLAsync('url', 123);

      BarCodeScanner.scanFromURLAsync('url', [
        // $ExpectError: invalid barcode type
        123,
      ]);
    });
  });
github flow-typed / flow-typed / definitions / npm / expo-barcode-scanner_v5.x.x / flow_v0.104.x- / test_expo-barcode-scanner.js View on Github external
it('should raises an error when call with invalid args', () => {
      // $ExpectError: first argument is required
      BarCodeScanner.scanFromURLAsync();

      // $ExpectError: first argument must be a string
      BarCodeScanner.scanFromURLAsync(123);

      // $ExpectError: second argument must be an array
      BarCodeScanner.scanFromURLAsync('url', 123);

      BarCodeScanner.scanFromURLAsync('url', [
        // $ExpectError: invalid barcode type
        123,
      ]);
    });
  });
github flow-typed / flow-typed / definitions / npm / expo-barcode-scanner_v5.x.x / flow_v0.104.x- / test_expo-barcode-scanner.js View on Github external
it('should pass when call with valid array of BarCodeType', () => {
      BarCodeScanner.scanFromURLAsync('url', [
        Constants.BarCodeType.qr,
        Constants.BarCodeType.aztec,
      ]);
    });

expo-barcode-scanner

Allows scanning variety of supported barcodes both as standalone module and as extension for expo-camera. It also allows scanning barcodes from existing images.

MIT
Latest version published 22 days ago

Package Health Score

92 / 100
Full package analysis