progress-component

0.0.4 • Public • Published

Progress

Circular progress indicator using canvas.

js progress indicator component

Installation

$ npm install progress-component

Example

var Progress = require('progress');
 
var progress = new Progress;
document.body.appendChild(progress.el);
 
var n = 0;
var id = setInterval(function(){
  if (== 100) clearInterval(id);
  progress.update(n++);
}, 50);

API

Progress#update(n)

Update the indicator to n and re-draw.

Progress#font(family)

Change the font to family.

Progress#fontSize(n)

Change the font size to n.

Progress#size(n)

Change the indicator diameter to n, defaults to 50.

License

MIT

Readme

Keywords

Package Sidebar

Install

npm i progress-component

Weekly Downloads

0

Version

0.0.4

License

none

Last publish

Collaborators

  • defunctzombie
  • dfcreative
  • jongleberry
  • dominicbarnes
  • tootallnate
  • rauchg
  • retrofox
  • coreh
  • forbeslindesay
  • kelonye
  • mattmueller
  • yields
  • anthonyshort
  • ianstormtaylor
  • cristiandouce
  • swatinem
  • stagas
  • amasad
  • juliangruber
  • calvinfo
  • blakeembrey
  • timoxley
  • jonathanong
  • queckezz
  • nami-doc
  • clintwood
  • thehydroimpulse
  • stephenmathieson
  • trevorgerhardt
  • timaschew
  • hughsk
  • tjholowaychuk