0.3.4 • Published 8 years ago

react-native-spring-carousel v0.3.4

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

react-native-spring-carousel

Carousel component for React Native implemented by View instead of ScrollView.

Support IOS and Android.

My image

Buy me a coffee if you like this

Install

$ npm install react-native-spring-carousel --save

Usage

require('react-native-spring-carousel');

...
onPressSlide(index){
  console.log(index);
},

render() {
          return (
                <Carousel
                width={width}
                height={height}
                pagerColor="#000"
                activePagerColor="#ff0000"
                pagerSize={10}
                pagerOffset={10}
                pagerMargin={2}
                speed={2000}
                onPress={this.onPressSlide}
                >
                   <View style={{width:width,height:300,backgroundColor:'#aaa',}}>
                     <Text>Page 1</Text>
                   </View>
                   <View style={{width:width,height:300,backgroundColor:'#bbb',}}>
                     <Text>Page 2</Text>
                   </View>
                   <View style={{width:width,height:300,backgroundColor:'#ccc',}}>
                     <Text>Page 3</Text>
                   </View>
                </Carousel>
          );
      }

Update

0.3.4 added support for RN 0.26 (thanks @cornedor )

0.3.2 remove listener onunmount

0.3.1 fixed onpress issue

0.3.0 added autoplay feature, you can define props - 'speed' to enable autoplay, remove speed to disable autoplay

0.2.1 bugs fixed

0.2.0 added onPress callback

todo

custom styles

0.3.4

8 years ago

0.3.3

8 years ago

0.3.2

8 years ago

0.3.1

8 years ago

0.3.0

8 years ago

0.2.4

8 years ago

0.2.3

8 years ago

0.2.2

8 years ago

0.2.1

8 years ago

0.2.0

8 years ago

0.1.11

8 years ago

0.1.10

8 years ago

0.1.9

8 years ago

0.1.8

8 years ago

0.1.7

8 years ago

0.1.6

8 years ago

0.1.5

8 years ago

0.1.4

8 years ago

0.1.3

8 years ago

0.1.2

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago