-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathApp.tsx
More file actions
46 lines (41 loc) · 1.28 KB
/
Copy pathApp.tsx
File metadata and controls
46 lines (41 loc) · 1.28 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/**
* IntelliVault - 您的本地智能文件助理
* @format
*/
import * as React from 'react';
import { useEffect } from 'react';
import { StatusBar, LogBox, StyleSheet } from 'react-native';
import { SafeAreaProvider, SafeAreaView } from 'react-native-safe-area-context';
import { AppNavigatorModern } from './src/core/navigation';
function App(): React.JSX.Element { useEffect(() => {
// 过滤掉一些已知的开发时警告
LogBox.ignoreLogs([
'Warning: The action \'NAVIGATE\' with payload',
'Warning: Text strings must be rendered within a <Text> component',
'Text strings must be rendered within a <Text> component',
'Do you have a screen named \'StreamChat\'?',
'LogBox.js',
'VirtualizedList: You have a large list',
]);
// 忽略所有的 console.error
LogBox.ignoreAllLogs(true);
}, []); return (
<SafeAreaProvider>
<SafeAreaView style={styles.container} edges={['top']}>
<StatusBar
barStyle="dark-content"
backgroundColor="#f8f9fa"
translucent={false}
/>
<AppNavigatorModern />
</SafeAreaView>
</SafeAreaProvider>
);
}
const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: '#f8f9fa',
},
});
export default App;