Counter-Up

Counter-Up is a lightweight jQuery plugin that counts up to a targeted number when the number becomes visible.

  • 所有者: bfintal/Counter-Up
  • 平台:
  • 許可證: GNU General Public License v2.0
  • 分類:
  • 主題:
  • 喜歡:
    0
      比較:

Github星跟蹤圖

Please use Counter-Up2 instead.

Counter-Up

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

  • integers 12345
  • floats 0.1234
  • formatted numbers 1,234,567.00

Features:

  • Auto-detect for integers, floats or formatted numbers
  • The plugin will also use the number of decimal places the original number is using.
  • Lightweight: ~1kb
  • Minimal setup

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="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+: +Benjamin Intal

主要指標

概覽
名稱與所有者bfintal/Counter-Up
主編程語言JavaScript
編程語言JavaScript (語言數: 1)
平台
許可證GNU General Public License v2.0
所有者活动
創建於2013-11-25 16:54:52
推送於2021-08-22 12:06:19
最后一次提交2021-08-22 20:06:19
發布數2
最新版本名稱1.0.0 (發布於 )
第一版名稱1.0 (發布於 )
用户参与
星數745
關注者數24
派生數710
提交數11
已啟用問題?
問題數52
打開的問題數46
拉請求數0
打開的拉請求數16
關閉的拉請求數9
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?