1.2.0 • Published 7 years ago

tsjing-carousel v1.2.0

Weekly downloads
3
License
ISC
Repository
github
Last release
7 years ago

Tsjing Carousel

This project is based on http://github.com/leecade/react-native-swiper. It does not support every feature of the original lib yet, but it resolves a lot of issues on both Android and iOS. It uses the native ViewPagerAndroid for Android and ScrollView for iOS with pagingEnabled.

Preview

How to use

  • Install via npm
npm i --save dejakob/tsjing-carousel
  • Import into your project
import Carousel from 'tsjing-carousel';

Properties

PropertyTypeDescription
onPageChangeFunctionFires when the page is changing with old page index, new page index
onPageChangeDoneFunctionFires when the page has changed with new page index
dotsHeaderComponentComponent to put above the navigation dots
dotsFooterComponentComponent to put below the navigation dots
dotsStyleObjectOverride styling of the dots navigation
dotStyleObjectOverride styling of an inactive dot
activeDotStyleObjectOverride styling of an active dot
autoPlayBooleanSlide the carousel automatically (false by default)
autoPlayTimeoutNumberTimeout between moving slides for the animation
indexNumberIndex of default page to show

To be implemented / Todo

  • Vertical carousel
  • Infinite paging (loop)
  • Unit tests

Tsjing logo