About CSS weight

Source: Internet
Author: User

The birthday of the jquery family has finally been well done. after a busy day, I am very tired.

Finally, you can sit down and stay idle. the CSS weight you pay attention to before the entire point.

In CSS, a 4-digit number is used to represent the weight.

The specific weights are described as follows:

The inherited style: 0000

Inline style: 1000

Sub-selector: 0000

Common selector: 0000

Attribute selector: 0010

Pseudo-class selector: 0010

Pseudo element selector: 0010

Type selector: 0001

Class selector: 0010

The maximum weight is displayed first.

I have been paying little attention in the past. Recently, I suddenly found that in some new projects, CSS weights are required for seamless integration.

If it is big, it cannot be displayed at all.

Well, write it down later when you pay more attention to it.

Converting from jquery http://www.jqueryba.com/267.html

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.