/**
* Sample React Native App
* https://github.com/facebook/react-native
*
* @format
* @flow strict-local
*/
import * as React from 'react';
import {SafeAreaView, ScrollView, View, StyleSheet, Text} from 'react-native';
import JailMonkey from 'jail-monkey';
export default function App() {
const [isDevelopmentSettingsMode, setIsDevelopmentSettingsMode] =
React.useState();
const [isDebuggedMode, setIsDebuggedMode] = React.useState();
React.useEffect(() => {
JailMonkey.isDevelopmentSettingsMode()
.then(value => {
setIsDevelopmentSettingsMode(value);
})
.catch(console.warn);
}, []);
React.useEffect(() => {
JailMonkey.isDebuggedMode()
.then(value => {
setIsDebuggedMode(value);
})
.catch(console.warn);
}, []);
return (
Android & iOS
Android
These APIs will always return false on iOS.
);
}
function Row({label, value}) {
return (
{label}:
{value?.toString() ?? 'unknown'}
);
}
const styles = StyleSheet.create({
root: {
flex: 1,
backgroundColor: '#fff',
},
content: {
padding: 20,
},
title: {
fontSize: 26,
color: '#000',
fontWeight: '700',
marginTop: 20,
marginBottom: 5,
},
note: {
fontSize: 11,
color: '#888',
marginBottom: 10,
},
row: {
flexDirection: 'row',
marginBottom: 5,
},
label: {
fontSize: 16,
color: '#444',
fontWeight: '700',
marginRight: 5,
},
value: {
fontSize: 16,
color: '#444',
},
});