Skip to content

Instantly share code, notes, and snippets.

@gHashTag
Created October 16, 2019 09:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gHashTag/8beaec836c6db8649ce0fd4e133ab232 to your computer and use it in GitHub Desktop.
Save gHashTag/8beaec836c6db8649ce0fd4e133ab232 to your computer and use it in GitHub Desktop.
import React, { memo } from 'react'
import { StyleSheet, Text, View } from 'react-native'
import { RED } from '../../constants'
const styles = StyleSheet.create({
container: {
alignItems: 'center',
margin: 10
},
h1: {
color: RED,
fontFamily: '3270Narrow',
fontSize: 13
}
})
const TextError = memo(({ title, onPress }) => {
const { container, h1 } = styles
return (
<View style={container}>
<Text style={h1} onPress={onPress}>
{title}
</Text>
</View>
)
})
export { TextError }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment