npm.io
0.0.2 • Published 11 years ago

mojo-animator

Licence
ISC
Version
0.0.2
Deps
1
Vulns
0
Weekly
0

Mojo Animator Build Status

Mojo animator is a plugin that leverages the browsers native requestAnimationFrame function to update the layout. It's used in paperclip, and mojo-views.

var Application = require("mojo-application");

var MyApplication = Application.extend({
  registerPlugins: function () {
    this.use(require("mojo-animator"));
  }
});

var app = new MojoApplication();

// calls requestAnimationFrame
app.animate({
  update: function () {
    // do something
  }
})