Quiet some ESLint errors (#1060)

Some via config, a few via code edits
This commit is contained in:
Pat Cavit 2016-05-19 22:18:31 -07:00
parent 79e4c4a104
commit 2ca8fa6e66
5 changed files with 16 additions and 7 deletions

View file

@ -2,12 +2,11 @@
module.exports = function(callback) {
//60fps translates to 16.6ms, round it down since setTimeout requires int
var time = 16
var time = 16
var last = 0, pending = null
var timeout = typeof requestAnimationFrame === "function" ? requestAnimationFrame : setTimeout
return function(synchronous) {
var now = new Date().getTime()
var diff = now - last
if (synchronous === true || last === 0 || now - last >= time) {
last = now
callback()