Highly customizable Timeline component for React Native (Android and iOS) and works with Expo.
If you're coming from react-native-listview
and simply want to use a FlatList
instead, then use the latest v1.x.x package instead. It'll be the path of least resistance.
A demo can be found on expo.
yarn add react-native-timeline-feed
or your favorite way...
You'll need the following imports
import Timeline from 'react-native-timeline-feed';
// only needed if you're going to select a non-default preset
import { Preset } from 'react-native-timeline-feed/lib/Types';
<Timeline data={data} />
or one of the presets
<Timeline
data={data}
preset={Preset.SingleColumnRight} />
Note. Color/Width specificity is as follows (highest priority to lowest): ItemProps -> TimelineProps -> defaults.