Skip to content

Instantly share code, notes, and snippets.

@rbhatia46
Created December 15, 2017 21:56
Show Gist options
  • Select an option

  • Save rbhatia46/1bd7b19823bc012eaf3bcd5933c99873 to your computer and use it in GitHub Desktop.

Select an option

Save rbhatia46/1bd7b19823bc012eaf3bcd5933c99873 to your computer and use it in GitHub Desktop.
Reusable Card Section Component for React Native
import React from 'react';
import { View } from 'react-native';
const CardSection = (props) => {
return(
<View style={styles.containerStyle}>
{props.children}
</View>
);
}
const styles = {
containerStyle: {
borderBottomWidth: 1,
padding: 5,
backgroundColor: '#fff',
justifyContent: 'flex-start',
flexDirection: 'row',
borderColor: '#ddd',
position: 'relative'
}
};
export default CardSection;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment