-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.js
More file actions
30 lines (24 loc) · 796 Bytes
/
index.js
File metadata and controls
30 lines (24 loc) · 796 Bytes
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
import React from 'react';
import { AppRegistry } from 'react-native';
import { Provider } from 'react-redux';
import Orientation from 'react-native-orientation';
import createStore from './state';
import buildTheme from './styles';
import { name as appName } from './app.json';
import { Navigator, setTopLevelNavigator } from './routes';
const store = createStore();
const theme = buildTheme();
console.disableYellowBox = true;
class Application extends React.Component {
componentDidMount() {
Orientation.lockToPortrait();
}
render() {
return (
<Provider store={store} key="provider" theme={theme}>
<Navigator ref={navigatorRef => setTopLevelNavigator(navigatorRef)} />
</Provider>
);
}
}
AppRegistry.registerComponent(appName, () => Application);