First things first, yes I know the render the same color, my question is is a simple query about speed.
This is just a topic of interest regarding optimising page load speeds, but which of the options in the title will render faster (even if it is the tiniest difference)?
My thought process is that with the shorthand version (#fff) the browser will be tasked with assuming the rest of the hex-dec is fff. On the other side the longhand version might take longer or less time because of the extra explicit characters.
I figured someone might be able to shed some light on the topic.
#fffis fewer characters, which is generally better. Network latency and bandwidth matter more than processing time in most cases. For this reason, most CSS compressors will intelligently optimize to the#fffversion. The network matters more than parsing speed in this case.If you’re concerned about parsing time, I doubt the difference between the 2 declarations accounts for even 0.005% of total parsing time. There are much bigger bottlenecks that dwarf any speed difference compared to parsing color declarations.