Found a cool peertube video of someone writing snake in some javascript framework they wrote and explaining step-by-step what they do. For any one interested in learning javascript or making some game in javascript, video is https://spectra.video/w/atYszPERdk5kuwuxAsUxn3