1.0.8 • Published 9 years ago

counter.js v1.0.8

Weekly downloads
18
License
MIT
Repository
github
Last release
9 years ago

Counter.js

Counter.js is a slim (less than 1kb gzipped), performant, ES6 module, that counts numbers. It uses RAF and easing functions to provide a buttery-smooth, 60-fps counter.

You can check out the demo here.

Install

npm install counter.js or include dist.min.js above.

Example

// if you’re not using a module bundler, include dist.min.js instead
import Counter from "counter.js";

// set your desired options
const opts = {
  start: 0,
  end: 100,
  selector: document.getElementById('count'),
  done: () => {
    // callback...
  }
};

// create an instance
const instance = new Counter(opts);

// run the counter
instance.run();
1.0.8

9 years ago

1.0.7

9 years ago

1.0.6

9 years ago

1.0.5

9 years ago

1.0.3

9 years ago

1.0.2

9 years ago

1.0.1

9 years ago

1.0.0

9 years ago