Closed DevSDK closed 3 years ago
There are drawBlocks()
function and reDraw()
function.
But the reDraw()
function is only call drawBlocks()
How about remove reDraw()
function, and change all calls to drawBlocks()
?
How about remove reDraw() function, and change all calls to drawBlocks()?
Done.
Without separate the renderer, the codes, and logics are growing complexity.
Therefore, Introduce 'renderer.js' which has been separated from the screen. This is more clear and extendable even possible to get performance in further.
The 'renderWithMerge(first, second)' worked as follow:
Statistically, The render function uses 0.5ms like [1].
[1] https://user-images.githubusercontent.com/18409763/111963150-88875f00-8b36-11eb-9258-68b0a2367245.png