對著敲了一下,有需要的同學可以參考一下https://github.com/shenguiming/promise/blob/master/ball.html
2018-07-27
創建一個新的包含字符串 'buffer' 的 UTF-8 字節的 Buffer
new Buffer (array) 變更為 Buffer.from(array)
new Buffer(bytelenth) 變更為 Buffer.alloc(size)
Buffer.allocUnsafe(size)創建一個指定字節的未初始化的Buffer對象
new Buffer (array) 變更為 Buffer.from(array)
new Buffer(bytelenth) 變更為 Buffer.alloc(size)
Buffer.allocUnsafe(size)創建一個指定字節的未初始化的Buffer對象
2018-07-27
style.marginLeft 報錯Cannot read property 'style' of undefined
刪掉下面這個方法的參數
function _animate() {...}
刪掉下面這個方法的參數
function _animate() {...}
2018-06-01
ball.style.marginLeft = marginLeft + 'px';
2018-06-01