ele.timer = setInterval (() => {
let nowTime = +new Date()
let timeDifference = Math.min(nowTime - startTime,duration)
for (let attr in options) {
let result = start[attr] + range[attr] / duration * timeDifference
ele.style[attr] = result + 'px'
}
if (timeDifference === duration) {
clearInterval(ele.timer)
fn && fn()
}
}, 10)