react-native-unit-components
Version:
Unit React Native components
20 lines • 692 B
JavaScript
import { NativeModules } from 'react-native';
const {
UNSnapshotProtectionManager
} = NativeModules;
class UNSnapshotProtectionHelper {
static setAndroidSecurity() {
/**
* Set secure flag on the activity's window (if it doesn't exist)
*/
UNSnapshotProtectionManager.setSecureFlags();
}
static setIosSecurity(shouldProtectFromSnapshot, style) {
/**
* Activate a Global native service for managing the snapshotProtection by the given arguments.
*/
UNSnapshotProtectionManager.configureSnapshotProtectionStrategy(shouldProtectFromSnapshot, style);
}
}
export default UNSnapshotProtectionHelper;
//# sourceMappingURL=UNSnapshotProtectionHelper.js.map