Re:Interop 2022: browsers working together to improve the we...
by onion2k on Sunday March 06, 2022 @03:11PM
(#30580777)
Apart from the duplicates (cm, inches, etc which can all be derived from mm with a basic calc) they all do different things. vw, vh, vmin, and vmax are useful for filling a screen, px is obviously related to the screen size, em, rem, ch and lh are relative to the current font or root font. There isn't much clutter there.
Re:Interop 2022: browsers working together to improve the we...
by esperent on Sunday March 06, 2022 @07:45PM
(#30582812)
You're missing quite a few. Here's all the size related CSS units I could find:
em
rem
ex
rex
cap
rcap
ch
rch
ic
ric
lh
rlh
vw
vh
vi
vb
vmin
vmax
And soon also:
dvh
lvh
svh
Taken from here
Re:Interop 2022: browsers working together to improve the we...
by onion2k on Monday March 07, 2022 @02:12AM
(#30585006)
I was illustrating how most of them aren't clutter. They do different things. This list just goes further to show that point - all the text related units refer to different aspects of the text, and they all need root and local versions. Same for screen space units like vw, vh, and so on. Any unit where you can't derive one from another means you need both.
There are some where you can do that. Absolute lengths like mm, cm, inch etc could just be one unit. Same for deg, rad and turn. Mostly though, CSS units are very well thought out, and it's easy to understand why the length units are included (USA vs metric).
Re:Interop 2022: browsers working together to improve the we...
by jdrc on Sunday March 06, 2022 @08:03PM
(#30582934)
what about flex units fr etc? they dont count?
Re:Interop 2022: browsers working together to improve the we...
by esperent on Sunday March 06, 2022 @08:39PM
(#30583240)
Please list any I missed. I only listed things you could set as width, height etc.
There's also units like Hz and so on.
Re:Interop 2022: browsers working together to improve the we...
by silviot on Sunday March 06, 2022 @02:53PM
(#30580612)
Obligatory XKCD: https://m.xkcd.com/927/
how many units does CSS have?? Shouldnt part of the improvement be to simplify and declutter the web's fundamentals?