title: Select back camera on html5-qrcode.min.js
body: <p>I use this qr code scanner:
  <a href="https://github.com/mebjas/html5-qrcode" rel="nofollow noreferrer">https://github.com/mebjas/html5-qrcode</a></p>
  <p>I use this code to scan qr code:</p>
  <pre><code>         function onScanSuccess(decodedText, decodedResult) {
    // handle the scanned code as you like, for example:
    document.getElementById('text').value = decodedText;
    console.log(`Code matched = ${decodedText}`, decodedResult);
  }
  
  function onScanFailure(error) {
    // handle scan failure, usually better to ignore and keep scanning.
    // for example:
    console.warn(`Code scan error = ${error}`);
  }
  
  let html5QrcodeScanner = new Html5QrcodeScanner(
      &quot;reader&quot;, { fps: 10, qrbox: 250 }, /* verbose= */ false);
  html5QrcodeScanner.render(onScanSuccess, onScanFailure);
  </code></pre>
  <p>It is possible to set default camera to back smartfone camera. I want to run scanner with setted back camera on startup.
  Thanks, for some help.</p>