Where is <span> covered?

please pass on where i can learn <span>

Hey @obxjuggler.

The span tag is mainly used for styling only parts of a paragraph differently. You can learn about the span element in the lesson and in the CC docs.

1 Like

While it does let us style its content differently, the element might be used to wrap a phrase in another human language:

<span title="let it be" lang="FR">laissez faire</span>

We may wish to style it, but that is a design consideration. The above is an accessibility requirement, namely, change of human language.

If we have multiple instances of language change, we can style it using an attribute selector:

span[lang] {
    font-style: italic; 

Bottom line, it is not just about styling, but well formedness.



in the typography lesson i see

<span class='bold text'>Abc</span>

there are other examples provided

what is going on here?

can my span be in the css too?

thanks again!

1 Like


.bold {
    font-weight: bold;
.text {
    font-family: Georgia, Times, serif;
    color: black;
    font-size: 1em;
span.text {
    font-style: italic;

See how the CSS selector rules are created for the above two classes? The last selector rule applies only to SPAN with class ‘text’.