Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
maithreya reddy addula
3,761 PointsSemantic markup or Not ?
Hi guys i am practicing my frontend knowledge. So i have downloaded a psd from http://diogodantas.com/designcode and coded only html but i am little worried whether i am writing a semantic markup or not.
http://jsbin.com/isiyIzO/2/edit?html,output
above is the code for my markup please check and let me know, i will improve whatever i have to and then will continue to css.
3 Answers
James Barnett
39,199 PointsYour markup looks ok, I'm not sure about your class names mainly because you don't have any CSS in your example.
Here are a few things to keep in mind about your class names:
The primary purpose of a class name is to be a hook for CSS and JavaScript. If you don’t need to add presentation and behavior to your web documents, then you probably don’t need classes in your HTML.
Class names impart little or no useful semantic information to machines
Class names should communicate useful information to developers.
source: http://nicolasgallagher.com/about-html-semantics-front-end-architecture/
Adam Sackfield
Courses Plus Student 19,663 PointsJames Barnett i would assume since he stated has only done the HTML then the classes are there ready for when he moves onto the CSS. I think there are too many div's still for semantic markup things like main-section and work etc could use the section tag and then further break down content inside each section with article tags.
Eduardo Garcia
4,571 PointsMaster the usage of the
<article>
tag, it may get confusing when you start nesting article tags within article tags but they are important to tell machines what the "meat" of a webpage is.
James Barnett
39,199 PointsIt sounds like you are describing the <section> element not the <article> element
Tom Bedford
15,645 PointsThat chart is great, haven't seen it before!
