bfintal / Counter-Up

Counter-Up is a lightweight jQuery plugin that counts up to a targeted number when the number becomes visible.
http://bfintal.github.io/Counter-Up/demo/demo.html
GNU General Public License v2.0
745 stars 718 forks source link

Please use Counter-Up2 instead, Counter Up 2 greatly improves on Counter Up, has no dependencies, lightweight, uses modern code, and more.

Counter-Up

Counter-Up is a jQuery plugin that animates a number from zero (counting up towards it). It supports counting up:

Features:

Requires waypoints.js

Demo

DEMO

Usage

Include

<script src="http://cdnjs.cloudflare.com/ajax/libs/waypoints/2.0.3/waypoints.min.js"></script>
<script src="https://github.com/bfintal/Counter-Up/raw/master/jquery.counterup.min.js"></script>

HTML

<span class="counter">1,234,567.00</span>
<span>$</span><span class="counter">1.99</span>
<span class="counter">12345</span>

jQuery

$('.counter').counterUp();

or with extra parameters

$('.counter').counterUp({
    delay: 10,
    time: 1000
});

delay - The delay in milliseconds per number count up

time - The total duration of the count up animation

Social Stuff

Twitter: @bfintal & @gambitph

Google+: