-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathindex.ios.js
More file actions
38 lines (36 loc) · 1004 Bytes
/
Copy pathindex.ios.js
File metadata and controls
38 lines (36 loc) · 1004 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
31
32
33
34
35
36
37
38
/**
* Sample React Native App
* https://github.com/facebook/react-native
* @flow
*/
import React, { Component } from 'react';
import {AppRegistry,
StyleSheet,
Text,
View,
Navigator
} from 'react-native';
import Main from './component/main/Main.js'
class MeiTuan extends Component{
// 构造
constructor(props) {
super(props);
// 初始状态
this.state = {};
}
render(){
return (
<Navigator
initialRoute={{name:'启动页',component:Main}}
configureScene={()=>{
return Navigator.SceneConfigs.PushFromRight;
}}
renderScene={(route,navigator)=>{
let Component = route.component;
return <Component {...route.passProps} navigator={navigator}/>;
}}
/>
);
}
}
AppRegistry.registerComponent('MeiTuan', () => MeiTuan);