This fork updates RN to 0.60.5, build tools 28.
A react native android module for obscuring applications when switching applications and preventing taking screenshots of the application.
$ npm install @talaikis/react-native-obscure --save
$ yarn add react-native-obscure
Nothing to do.
You can use it programmatically for activating/deactivating the obscuring at any time, use it app-wide or per component.
activateObscure
: Activates the obscuring.
deactivateObscure
: Deactivate the obscuring.
import React, { Component } from 'react';
import { View, Text } from 'react-native';
import Obscure from 'react-native-obscure';
export default class App extends Component {
componentWillMount() {
Obscure.activateObscure();
}
componentWillUnmount() {
Obscure.deactivateObscure();
}
render() {
return(
<View>
<Text>This text will be obscured when changing apps</Text>
</View>
);
}
}
- Add iOS support.