3 ms·
I started using alphabetic ordering for CSS some time back, and have found it much easier and more reliable than trying to keep CSS organized by importance / re
by caseyross 4y ago
I started using alphabetic ordering for CSS some time back, and have found it much easier and more reliable than trying to keep CSS organized by importance / relevance / semantic content.
One correction to the article I want to make is that shorthand/longhand properties are more naturally alphabetized by placing the shorthand property first (rather than the opposite, as suggested by the author), so overriding them shouldn't ever be a problem.
- somishere 4y agoCompletely agree. Apologies I made a separate comment re. the short/longhand concern. I wonder if this is an IDE specific issue or is the author referring to manually ordering?
- jamesfinlayson 4y agoAgreed - alphabetical is the one ordering that everyone knows, whereas importance or concentricity or whatever require memorising or looking up. Ordering the properties at all probably isn't hugely important but if some declaration has 15+ properties, I like that I can zero in on the one I'm looking for rather than scanning each property or having to Ctrl+F to find what I'm looking for.