I'm curious about HTML class

Asked 1 years ago, Updated 1 years ago, 83 views

    <div class="site-search site-search--full">
    </div>

If it's like this, should I do a .site-search when I use it in css? Does site-search--full represent an additional explanation?

For another example, When you use the icon with fontaeseome, fa fa fa ha ha ha ha ha ha ha ha ha ha ha ha ha haha I don't understand! Please organize it easily

html5 tag

2022-09-21 19:34

2 Answers

I don't know what you'd like to hear, but I'll give you a link for your reference.

I'm leaving a reference because I think you're curious about css Selector.

w3school CSS Selector

MDN CSS Selector

And there can be multiple classes. Space bar is separated into different independent classes through a space character. You can understand that a class called site-search is applied, and a class named site-search--full is applied. Alternatively, you can apply it as in the example created by the top.

fa fa- You can think of it as an abbreviation somehow.


2022-09-21 19:34

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.