Skip to content

Instantly share code, notes, and snippets.

@ShanikaNishadhi
Created November 19, 2020 22:03
Show Gist options
  • Save ShanikaNishadhi/38a7e3f079672531887a930769694876 to your computer and use it in GitHub Desktop.
Save ShanikaNishadhi/38a7e3f079672531887a930769694876 to your computer and use it in GitHub Desktop.
DeviceInfo.isCameraPresent()
.then(isCameraPresent => {
// true or false
})
.catch(cameraAccessException => {
// is thrown if a camera device could not be queried or opened by the CameraManager on Android
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment