Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

Commit df5c6ed

Browse files
committed
Merge pull request #18 from mobify/fix-sentence
Clarify the section on Attribute Selectors
2 parents fbf920f + c7c227a commit df5c6ed

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

css/Readme.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -83,11 +83,13 @@ ul.button-group li.button {
8383

8484
## A Note On Attribute Selectors
8585

86-
Attribute selectors are often overlooked, and when they are noticed that are often qualified alongside an element selector. For example `input[type="text"]`.
86+
A common use case is to target input types. For example `input[type="text"]`.
8787

88-
It's important to realize that the element selector is not necessary and actually increases the specificity!
88+
It's important to realize that the element selector is not necessary here. If you think about it, we are actually increasing the specificity needlessly.
8989

90-
So for that reason, attribute selectors should be used alone, just like classes.
90+
All we really need is `[type="text"]`
91+
92+
So for that reason, *attribute selectors should be used alone*, just like classes.
9193

9294
## Class Naming Convention
9395

0 commit comments

Comments
 (0)