1.0.1 • Published 8 years ago

react-native-common-item-cell v1.0.1

Weekly downloads
1
License
MIT
Repository
github
Last release
8 years ago

react-native-common-item-cell

A React Native item cell. The cell grows with the inner text. This project is forked from react-native-item-cell, I add the left title in it .

Install

Install the package:

$ npm i react-native-common-item-cell --save

Install FontAwesome from the awesome Joel Oblador's react-native-vector-icons: https://github.com/oblador/react-native-vector-icons#installation

Usage

import ItemCell from 'react-native-common-item-cell';
<ItemCell>
  Item
</ItemCell>
<ItemCell icon={{uri: 'https://ss0.bdstatic.com/5aV1bjqh_Q23odCf/static/superman/img/logo/bd_logo1_31bdc765.png'}}>
  Item
</ItemCell>
<ItemCell title = {"Gender:"} showDisclosureIndicator={true}
onPress ={()=>console.log("pressme")}
onPressOut ={()=>console.log("pressme out")}>
  Man
</ItemCell>

Prop API

PropTypeDescription
showDisclosureIndicatorboolShows a small arrow at the right side of the cell.
icon{uri: string} object or require()URI to render left icon with an URL for the image source or require for a local image source.
childrenstringThe inner text to render.
titlestringThe left title text to render.

License

MIT