The second example is likely to work better, but the question is about weighting performance versus context.
For example, in the second example, you say that any anchor element that is a descendant of any element with the email-me
identifier must have a style. The question is, what do you really mean?
For example, if on another page another element should use the email-me
identifier, we can say that the element is a div
, should the links inside it receive the same style? Do you really want to say? If so, then great.
If not, do you really mean the context described in the first example: only bindings that are descendants of a list item with email-me
identifier, which are descendants of an unordered list that are inside the navigation section of the page.
I would say that, as before , it really depends on what you are trying to say. But I would say that most of the time, sacrificing specificity / clarity for performance, is not a good deal.
source share