This is my little gift for my girlfriend to play some old games her younger self liked very much.
Enjoy!
You need to run this from a server. I'm using the plugin "Live Server" to run & dispose of a server from Visual Studio Code anytime I need it.
If I've got some spare time, I might think to properly implement a pause button using the P key (yes, only setting the inputDirection back to { x: 0, y: 0 } is not enough). I'd also want to get rid of those <div> generation and use a <canvas>. Also want to display a real snake instead of blocks. But this will be for a different story!