A text fragment hasn't limits on words. Thus we can use the span for any text. The p is paragraph. The problem is we don't have single opinion what a paragraph is. I think a paragraph is sequence of text blocks that are united by one meaning.
When we do our HTML code reviews, we count the non-semantic tags like <span> - they are are considered a code-smell - that indicates something might be going wrong...
The fact that you say the span isn't semantic element is the span is semantic element because if it don't have semantic (meaning) you can't do it. And just read specs
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
A text fragment hasn't limits on words. Thus we can use the
span
for any text. Thep
is paragraph. The problem is we don't have single opinion what a paragraph is. I think a paragraph is sequence of text blocks that are united by one meaning.I mostly agree with you.
I think there is an even higher zeroth law for HTML goodness, which is something like:
Always use accurate SEMANTIC HTML wherever possible
This article explains it better than I can: w3schools.com/html/html5_semantic_...
When we do our HTML code reviews, we count the non-semantic tags like
<span>
- they are are considered a code-smell - that indicates something might be going wrong...Semantic-HTML is good for the soul. Namaste.
The
span
is the same semantic element like otherNo its not :-)
Check the w3schools intro to semantics - right at the top, around the 3rd line...
is a non-semantic element.
The fact that you say the
span
isn't semantic element is thespan
is semantic element because if it don't have semantic (meaning) you can't do it. And just read specs