import React, { Component } from "react"
import { View, Text } from "react-native"
import PropTypes from "prop-types"
class ${NAME} extends Component {
constructor(props) {
super(props)
this.state = {}
}
static propTypes = {
//define the prop types
// tempStr: PropTypes.string,
// tempMethod: PropTypes.object
// onClickRightIcon: PropTypes.func.isRequired
}
static defaultProps = {
//default values for props
}
render() {
const { ...props } = this.props
return (
<View>
<Text>hello word</Text>
</View>
)
}
}
const styles = StyleSheet.create({
xxx: {}
})
export default ${NAME}
[RN]component 模板
最新推荐文章于 2022-07-22 17:35:26 发布