Are Undefined CSS Classnames in IE7 and IE8 Expensive?

If class names are specified in HTML but not defined in CSS, is there a performance limitation in IE7, IE8, or Firefox?

<div class="undefined_class">Text</div>
+5
source share
2 answers

There is no particular punishment (this is simply a matter of increasing the size of the document), but the class does not have to be defined for styling purposes. It can also be used to manipulate the DOM with javascript

+4
source

No. You do not define classes in CSS, you write the rules that apply to this class using the CSS class selector, or .. You define the class for this element in html.

0
source

All Articles