r/shittyprogramming • • Apr 12 '16

Easy JavaScript game loop

Post image
277 Upvotes

37 comments sorted by

View all comments

6

u/nohimn Apr 12 '16

function bar() { console.log('BAR'); setTimeout(foo, 1); }

Fixed it for ya.