3 ms·
see above :)
by grvcoelho 11y ago
see above :)
- johnhenry 11y agoI see the issue of specificity, but instead of writing this .search-form { > .submit {} }, wouldn't you write this as .search-form { .submit {} }, and this would compile to .search-form .submit {}? I don't see the issue with nesting itself -- it still seems like the choices of the programmer are at fault in this case?
- grvcoelho 11y agoThe problem is not with the ">", but with the specificity in general! The selector ".search-form .submit" has 2 levels if specificity. What I suggest is using 1 level of specificity like ".search-form__submit" Nesting is guilty here because of the ease it is to use it wrongly and create selectors with high levels of specificity