Back in my day you had to have flash enabled to play creative in the browser! ๐ง
Programming
Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!
Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.
Hope you enjoy the instance!
Rules
Rules
- Follow the programming.dev instance rules
- Keep content related to programming in some way
- If you're posting long videos try to add in some form of tldr for those who don't want to watch videos
Wormhole
Follow the wormhole through a path of communities !webdev@programming.dev
Impressive and definitely my cup of tea.
There isn't actually all that much CSS, but 46 000 lines of html, mostly elements for some reason.
Well, in order to avoid JavaScript, it's having to encode all seven possible block states for all possible cells of the 10ร8ร8 world, and they've chosen to use HTML "radio" buttons - a single element - to achieve this. Each radio option has its own label, which, rather than text, is a heavily stylised set of six objects that represent the sides of the cube, which only show up when their respective radio option is set.
7ร10ร8ร8ร(1+6) = 40320. The remainder of the lines are basically everything else.
In theory you could have JavaScript generate this on the fly directly into the DOM, and the "game" would still work without needing JavaScript to actually handle any of it, but since they've opted to avoid JavaScript altogether, they've obviously pre-generated the majority of it with some other language.
I think the point is to show off that you don't really need Javascript for the things it's often abused.
Yeah, why write 100 lines if you can write 40k instead right?
A lot of repetition. I guess if HTML had functions, the document would be 40 000 lines shorter.