giving good starting point
adding steps doc
adding requestanimationframe
adding fixed code
adding fixed code