Carousel

Simple carousel component.
Check out tomerdmnt/carousel-slide for the same thing with slide transition.

    

1

2

3


    var Carousel = require('carousel');
var c = Carousel(document.getElementById('myCarousel');

// show next item
c.next();

// show previous item
c.prev();

Installation

$ component install tomerdmnt/carousel

API

(el)

Binds to the container element of the carousel.

next()

Show the next item. if there is none returns null.

prev()

Show the previous item. if there is none returns null.

License

MIT