Skip to content

Instantly share code, notes, and snippets.

@rafinskipg
Last active March 6, 2020 07:25
Show Gist options
  • Save rafinskipg/15e1390dda1d2942b5c9cbc9ec86888d to your computer and use it in GitHub Desktop.
Save rafinskipg/15e1390dda1d2942b5c9cbc9ec86888d to your computer and use it in GitHub Desktop.
function loop() {
const now = Date.now()
dt = (now - before) / 1000
// update(dt)
render()
before = now
window.requestAnimationFrame(loop)
}
loop()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment