Skip to content

Latest commit

 

History

History
53 lines (39 loc) · 1.25 KB

README.md

File metadata and controls

53 lines (39 loc) · 1.25 KB

Carousel component for React Native

NPM version

Circular carousel for react-native. Supports iOS, Android and Web (react-native-web).

Demo

Demo

Install

npm install react-native-lfcarousel --save

Full example code

Usage

import React from 'react';
import { StyleSheet, View } from 'react-native';
import Carousel from 'react-native-lfcarousel';

const styles = StyleSheet.create({
  container: {
    flex: 1,
  },
});

function App() {
  return (
    <Carousel
      style={styles.container}
      speed={2000}
      pagerColor="#000"
      activePagerColor="#fff"
    >
      <View style={{ flex: 1, backgroundColor: 'red' }} />
      <View style={{ flex: 1, backgroundColor: 'green' }} />
      <View style={{ flex: 1, backgroundColor: 'blue' }} />
    </Carousel>
  );
}

export default App;

License

react-native-lfcarousel is licensed under the MIT License.