A QR code & Barcode Scanner for React Native Projects. It supports React Native's new Fabric Native architecture and was created in Kotlin and Objective-C.
This update introduces significant enhancements to the @pushpendersingh/react-native-scanner package, notably the addition of a flashlight feature for Android devices and the ability to release the camera resources properly. Key changes include:
Flashlight Feature for Android: The README.md has been updated to document a new flashlight feature that allows users to turn the flashlight on and off, enhancing the barcode and QR code scanning experience in low light conditions. This feature is specifically designed for Android devices and is detailed under the "Flashlight Feature (Android Only)" section with comprehensive usage examples.
Camera Release Functionality: To improve resource management, a new function releaseCamera has been introduced, ensuring that camera resources are properly released when the component is unmounted or no longer in use. This is particularly important for preventing app crashes and ensuring that the camera can be used by other components or applications thereafter.
Documentation Updates: The README.md file has been significantly expanded to include instructions for enabling the new architecture on iOS, detailed examples of basic usage, and a dedicated section for the newly introduced flashlight feature. This includes code snippets and explanations for permissions handling, enabling/disabling the flashlight, and ensuring proper camera permission is granted.
Code Enhancements: On the code side, modifications include updates to the ReactNativeScannerView Kotlin class to support flashlight operations (enableFlashlight and disableFlashlight) and camera release (releaseCamera). Corresponding commands have been added to the ReactNativeScannerViewManager Kotlin class and the ReactNativeScannerViewNativeComponent TypeScript definition to expose these functionalities to React Native.
Version Bump: The package version has been updated to 1.2.0-beta.1 to reflect these new features and improvements.
These changes aim to enhance the usability and functionality of the @pushpendersingh/react-native-scanner package, making it a more versatile tool for React Native developers looking to integrate barcode and QR code scanning capabilities into their applications.
This update introduces significant enhancements to the
@pushpendersingh/react-native-scanner
package, notably the addition of a flashlight feature for Android devices and the ability to release the camera resources properly. Key changes include:Flashlight Feature for Android: The README.md has been updated to document a new flashlight feature that allows users to turn the flashlight on and off, enhancing the barcode and QR code scanning experience in low light conditions. This feature is specifically designed for Android devices and is detailed under the "Flashlight Feature (Android Only)" section with comprehensive usage examples.
Camera Release Functionality: To improve resource management, a new function
releaseCamera
has been introduced, ensuring that camera resources are properly released when the component is unmounted or no longer in use. This is particularly important for preventing app crashes and ensuring that the camera can be used by other components or applications thereafter.Documentation Updates: The README.md file has been significantly expanded to include instructions for enabling the new architecture on iOS, detailed examples of basic usage, and a dedicated section for the newly introduced flashlight feature. This includes code snippets and explanations for permissions handling, enabling/disabling the flashlight, and ensuring proper camera permission is granted.
Code Enhancements: On the code side, modifications include updates to the ReactNativeScannerView Kotlin class to support flashlight operations (
enableFlashlight
anddisableFlashlight
) and camera release (releaseCamera
). Corresponding commands have been added to the ReactNativeScannerViewManager Kotlin class and the ReactNativeScannerViewNativeComponent TypeScript definition to expose these functionalities to React Native.Version Bump: The package version has been updated to
1.2.0-beta.1
to reflect these new features and improvements.These changes aim to enhance the usability and functionality of the
@pushpendersingh/react-native-scanner
package, making it a more versatile tool for React Native developers looking to integrate barcode and QR code scanning capabilities into their applications.