Just a quick query out of the following two code snippets which would be the most optimal. Assuming minification, file size for the second win’s, but i wonder how it would affect rendering time and which would come out on top, (yuh i know its probably insignificant, just wondering)
This reply has been reported for inappropriate content.
hah I slipped up there, writing out code for the question, i should have made .codesegmentB alter something like border-width or margin instead so that they couldn’t be merged with .codesegmentA when been zero’d, my bad. As for readability, Yuh its much cleaner, though deployed code is minified so not as super high issue as im the only one working with it.
It was more of a question of are their any extra overheads in page rendering by having the codesegment A & B in #1 outside of a media query therefore the defacto default for those classes and having to zero them inside the media query(browser applies the adjusted value first then overrides it with the zero’ed value), Versus in #2 having the codesegment A & B set only within a mediaquery, therefore not needing to zero them in the later media query. Because if there aren’t and your ignoring readability file size becomes the priority for optimization.