Best practices for classes


show more Best practices for classes provides you with in-depth training on Web. Taught by Eric Meyer as part of the CSS Web Site Design show less
please wait ...

Best practices for classes

As a follow on to the previous video I just want to take a minute to talk about a few best practices when it comes to classes. It can be very tempting to over class as it were, to end classes really nearly and I hit her in Jan. Just on the off chance that you might need them some day. As an example here in this document, you can see where we have these list items here that contain links that are navigation links and every one of these list items has a class of navlink and in the a element, inside them have classes of navlinks and this is really, really, really inefficient.

There's no need for all of this navlinking classing to happen here. Instead, you could just take all that out so that instead of having classes everywhere, you just have these plain elements and then you might wonder to yourself well, how am I supposed to select those. Well, that's coming up later in the chapter, about the short preview answer is that you use the ID up here on the element that encloses all thes...

Best practices for classes
Video duration: 4m 52s 6h 8m Intermediate

Viewers:

Best practices for classes provides you with in-depth training on Web. Taught by Eric Meyer as part of the CSS Web Site Design

Subject:
Web
Software:
CSS
Author:
please wait ...