- The universal selector is one of the oddest…and least understood selectors in all of CSS.…Represented simply by an asterisk,…this selector matches every element type in your document.…Now, this can be extremely useful for doing things like…CSS resets or setting defaults for specific properties…like box sizing, but the universal selector…can also have some downright odd effects.…So before using it,…it's really helpful to understand its behavior.…So, getting a little deeper into the syntax,…I'm gonna scroll down here.…
I have the universal.htm file opened up from…the 01_06 directory.…Right now, I have opened up in the browser, obviously.…And if I go down to the syntax section, you can see…all you need to write this selector is the asterisk.…That's it.…When you do that, the browser is gonna return…every single element on the page,…which can be great and can be really odd.…We can also combine it in a descendant selector.…You can see the example below that is…div space asterisk space em.…
That's gonna target any em…
- Targeting classes and IDs
- Working with group selectors
- Targeting element attributes
- String matching
- Targeting links with pseudo-class selectors
- Targeting child elements and empty elements
- Targeting parent, child, and sibling elements
- Matching patterns
- Writing efficient selectors
Skill Level Intermediate
CSS: Advanced Typographic Techniqueswith James Williamson3h 14m Intermediate
1. Basic Selectors
2. Attribute Selectors
3. User Action Pseudo-Class Selectors
4. Structural Selectors
6. Matching Patterns
7. Writing Efficient Selectors
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.