Game rendering loop using canvas and TypeScript | Hacker News Reader