1.2.0 • Published 5 years ago

@gluedigital/scroll-carousel v1.2.0

Weekly downloads
4
License
MIT
Repository
-
Last release
5 years ago

scroll-carousel

A library for scroll-driven vertical carousels.

Usage

To install it:

npm install --save @gluedigital/scroll-carousel

To use it:

import ScrollCarousel from '@gluedigital/scroll-carousel'
import '@gluedigital/scroll-carousel/css/index.css'

// ...

<ScrollCarousel>
  <div>First slide</div>
  <div>Second slide</div>
  <div>Last slide</div>
</ScrollCarousel>

Options

The following props can be used:

NameTypeDescription
classNamestringBase classname to use. Status classes will be added to it.
timeoutnumberHow long should the leaving slide stay on the DOM, in ms.

Developing

This package uses nwb for the build. Take a look at their documentation for more info.

TL;DR: after installing nwb, just do npm start to open the dev environment.