# vigour-carousel

> vigour carousel

Latest version **1.2.1** (published 2016-04-04) · MIT license · 0 weekly downloads

## Install

```sh
npm install vigour-carousel
pnpm add vigour-carousel
yarn add vigour-carousel
bun add vigour-carousel
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.2.1 |
| Published | 2016-04-04 |
| First published | 2016-02-24 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | vigour.io |
| Maintainers | vigour-io |
| Keywords | vigour-element, carousel, DOM |

## Links

- npm: https://www.npmjs.com/package/vigour-carousel
- Repository: https://github.com/vigour-io/carousel
- Issues: https://github.com/vigour-io/carousel/issues
- npm.io page: https://npm.io/package/vigour-carousel

## Dependencies (2)

- [vigour-util](https://npm.io/package/vigour-util.md) ^1.3.0
- [vigour-style](https://npm.io/package/vigour-style.md) ^1.0.0

## Alternatives

- [babylon](https://npm.io/package/babylon.md) — 5.1M weekly downloads
- [csscolorparser](https://npm.io/package/csscolorparser.md) — 3.7M weekly downloads
- [expr-eval-fork](https://npm.io/package/expr-eval-fork.md) — 1.5M weekly downloads
- [@leeoniya/ufuzzy](https://npm.io/package/@leeoniya/ufuzzy.md) — 247.7K weekly downloads
- [xml-parser](https://npm.io/package/xml-parser.md) — 78.4K weekly downloads

## Recent versions

- 1.2.1 (latest) — 2016-04-04
- 1.2.0 — 2016-04-04
- 1.0.9 — 2016-03-24
- 1.0.8 — 2016-03-23
- 1.0.7 — 2016-03-09
- 1.0.6 — 2016-03-04
- 1.0.5 — 2016-02-28
- 1.0.4 — 2016-02-27
- 1.0.3 — 2016-02-26
- 1.0.2 — 2016-02-25
- 1.0.1 — 2016-02-24
- 1.0.0 — 2016-02-24

## README

# carousel
[![js-standard-style](https://img.shields.io/badge/code%20style-standard-brightgreen.svg)](http://standardjs.com/)
[![npm version](https://badge.fury.io/js/vigour-carousel.svg)](https://badge.fury.io/js/vigour-carousel)
[![Build Status](https://travis-ci.org/vigour-io/carousel.svg?branch=master)](https://travis-ci.org/vigour-io/carousel)

An infinite carousel for usage with [vigour-element](https://github.com/vigour-io/element).

## how to use
`npm i --save vigour-carousel`

Add the carousel to your app as a component, define the `$collection` for it's items and add the data.

The carousel exposes `.next()` and `.previous()` methods.

##setup

```js
var e = require('vigour-element')
var carousel = require('vigour-carousel')

// define some data
var Observable = require('vigour-observable')
var Data = new Observable({
  inject: require('vigour-observable/lib/data'),
  Child: 'Constructor'
}).Constructor

// it expects a "focus" field (this will be used to store the current slide)
var carouselData = new Data({
  focus: 0,
  0:{},
  1:{},
  2:{},
  3:{}
})

// add carousel component to your app
var app = e({
  components: {
    carousel: carousel
  },
  DOM: document.body
})

// add your carousel
app.set({
  myCarousel: {
    type: 'carousel',
    items:{
      $collection: true
    }
  }
})

// add data to app
app.val = carouselData
```

---
_Source: https://npm.io/package/vigour-carousel · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
