UNPKG

rn-project

Version:

#### 项目介绍 类似一个脚手架的工具 此项目致力于构建一套基础,简单,可维护的 适配我司的react-native项目。可在此基础上搭建项目,封装了基础架构,基础组件,以及各种交互等;可快速进行项目搭建,开发。 # 涉及主要技术 - 1. 项目主要架构 * react native * react-navigation * redux

28 lines (24 loc) 658 B
import React, { Component } from 'react'; import { Text, Button } from 'react-native'; import PropTypes from 'prop-types'; import { SafeAreaView } from 'react-navigation'; import BaseStyle from '../constants/Style'; export default class RegistScreen extends Component { static propTypes = { navigation: PropTypes.object, }; render() { const { navigation: { navigate }, } = this.props; return ( <SafeAreaView style={BaseStyle.flex}> <Text>register!</Text> <Button title="Go to Details" onPress={() => navigate('Details', { user: 'Lucy' })} /> </SafeAreaView> ); } }