Skip to content

A minified snake game, written in html, js and css. Exactly 1.8kb

scratching-claws/smallSnake

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

smallSnake

A minified snake game, written in html, js and css. Exactly 1.8kb

The file smallSnake.html is my ultimate version, which I minified myself.

The file snake.html is the version of the game as I first programmed it. Not all of the variables are shortened, but it is an accurate representation of how I think when programming.

Both programs do not follow best practices for variable naming, and normally I would not program in this way if I wanted to work on the code later.

The smaller version does have some additional features which I added after I finished minifying it and I still had some spare space.

While the variables are atrocious, the game should actually be quite easy to expand and build upon, and I welcome forks of this repository.

If you want a bit of a challenge, try to un-minify the file smallSnake.html, to work out what each variable does. I made a list of variable names and functions somewhere while working on the project, and so I have the answers if anyone has a burning question about a specific part of the code.

About

A minified snake game, written in html, js and css. Exactly 1.8kb

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published