DEV Community

Ben Halpern
Ben Halpern

Posted on

Table Tennis in Pure HTML CSS 🤯

No JavaScript to be found here:

Latest comments (28)

Collapse
 
carmensstanley profile image
Carmen S. Stanley • Edited

WOW! This is so cool tennis court. Really appreciated. Actually, you should play tennis as well, I believe you will do wonders there as well.

Collapse
 
rickyreyes profile image
RickyReyes

Wow! That's insane. Well done.

Collapse
 
alin11 profile image
Ali Nazari

I can only do "display: block" with CSS

Collapse
 
davinderpalrehal profile image
Davinderpal Singh Rehal

That is a level of CSS I can only dream of having.... trying to reproduce some of these effects to learn from

Collapse
 
kevindublin profile image
Vin Dublin

Wow. Even the ball's shadow. This must've been super fun to create.

Collapse
 
lankabhedi profile image
Sam

The comment section did not pass the vibe check.

Collapse
 
gypsydave5 profile image
David Wickes

but why

Collapse
 
taikedz profile image
Tai Kedzierski • Edited

OK, nope, I am legit impressed. Copied the HTML and compiled CSS into a local file, removed the sole font import. Totally works. From what I can see, leveraging webkit animation instructions and deterministic re-calculations that make it look like a random game...

Reminds me of the feats done with palette shifting for animating 8-bit scenes and even drawing completely new images into a static array of non-changing bits.

Collapse
 
lautarolobo profile image
Lautaro Lobo

Cool!!

Collapse
 
rahulbanerjee99 profile image
Rahul Banerjee

This looks really cool!

Collapse
 
lepinekong profile image
lepinekong

Wow :)

Collapse
 
mzaini30 profile image
Zen

Sass is JS in CSS 😂

Collapse
 
tyler320sc profile image
Tyler Carroll

Really cool!

 
ben profile image
Ben Halpern

Of course this in particular is more for art and experimentation than practicality, but there are certain situations where constraints exist for very valid reasons (security being a huge one)... It's not impossible, but much harder to, say, pull XSS without a full programming language running.

Thread Thread
 
afif profile image
Temani Afif • Edited

@lifelongthinker it was a rhetorical question :)

Collapse
 
heymich profile image
Michael Hungbo

This is amazing!