How to use the expo-barcode-scanner.BarCodeScanner.requestPermissionsAsync 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 expo / expo / docs / static / examples / unversioned / bar-code-scanner.js View on Github external
(async () => {
      const { status } = await BarCodeScanner.requestPermissionsAsync();
      setHasPermission(status === 'granted');
    })();
  }, []);

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 8 months ago

Package Health Score

85 / 100
Full package analysis