forked from brentvatne/signature-example
-
Notifications
You must be signed in to change notification settings - Fork 7
/
main.js
36 lines (31 loc) · 954 Bytes
/
main.js
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
import Exponent from 'exponent';
import React from 'react';
import { Platform, StatusBar, View,
StyleSheet } from 'react-native';
import { createRouter, NavigationProvider, StackNavigation } from '@exponent/ex-navigation';
import SignatureScreen from './screens/SignatureScreen';
const Router = createRouter(() => ({
signature: () => SignatureScreen
}));
class App extends React.Component {
render() {
return (
<View style={styles.container}>
<NavigationProvider router={Router}>
<StackNavigation
initialRoute={Router.getRoute('signature')}
/>
</NavigationProvider>
{Platform.OS === 'ios' && <StatusBar barStyle="default" />}
{Platform.OS === 'android' && <View style={styles.statusBarUnderlay} />}
</View>
);
}
}
const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: '#EEE'
}
});
Exponent.registerRootComponent(App);