In CSS, Some Infinities Go Beyond
3 min readApr 9, 2024
You’re probably familiar with CSS units such as px
, rem
, em
, and maybe even more exotic units like dvh
, deg
or kHz
, but there is another value that (as of April 5, 2024) isn’t even listed on MDN’s CSS Values and Units, and that is infinity
.
I’m going to burst your bubble right now though, and tell you that infinity
is not actually infinite. Depending on your browser, when infinity
is used on the width
…