Is it possible to visually display html attributes which normally only reside in the source code, in the output of html, anchored to the element they are grouped with?
For example, here is some css which visually groups some <span></span> tags in rounded rectangles for clarity:
span{
display:inline-block;
}
span:first-child{
border:1px solid black;
border-radius:15px;
padding:10px;
}
span:last-child{
border:1px solid black;
border-radius:15px;
padding:10px;
}
<span class="complete-sentence">She <span class="verb">loves</span> him a <span>lot</span>.</span>
https://jsfiddle.net/ycpw4tzz/ <-- What happens currently.
Two of the span tags have classes (global attributes) of "subject" and "verb". I want to somehow get the output display to look like this instead of what it does currently.
