Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Flexible spinner using canvas.
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
test
.gitignore
Readme.md
index.js
package.json

Readme.md

spinner-browserify

Flexible spinner using canvas, a fork of godmodelabs/spinner.

js spinner component

Check out the demo!

Installation

$ npm install spinner-browserify

Example

var Spinner = require('spinner-browserify');

var spinner = new Spinner;
document.body.appendChild(spinner.el);

API

Spinner#light()

Change the spinner to the light theme.

Spinner#font(family)

Change the font to family.

Spinner#fontSize(n)

Change the font size to n.

Spinner#text(value)

Set the text inside the spinner to value.

Spinner#size(n)

Change the indicator diameter to n, defaults to 50.

Spinner#speed(n)

Change the speed to n rpm, defaults to 60.

Spinner#stop()

Stop the animation. This is important when removing the spinner, otherwise the requestAnimationFrame cycle will continue.

License

MIT

Something went wrong with that request. Please try again.