codemarch Profile picture
Jan 20 7 tweets 2 min read
A quick glance at "CSS Specificity"

Thread🧵
🔶 CSS Specificity

If there are two or more CSS rules that point to the same element, the selector with the highest specificity value will "win", and its style declaration will be applied to that HTML element.
There are four categories that define the specificity level of a selector:

1. Inline styles - Example: <h1 style="color: pink;">

2.IDs - Example: #navbar
3.Classes, pseudo-classes, attribute selectors - Example: .test, :hover, [href]

4.Elements and pseudo-elements -
Example: h1, :before
🔶 How to Calculate Specificity?

Memorize how to calculate specificity!

Start at 0, add 100 for each ID value, add 10 for each class value (or pseudo-class or attribute selector), add 1 for each element selector or pseudo-element.
Example-
if you enjoyed this thread, please like, comment, and retweet the opening tweet.
🔹Follow @codemarch
🔹You can also check our HTML & CSS Visual Treat!😍for more!!!
codemarch.gumroad.com/l/hxazr

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with codemarch

codemarch Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @codemarch

Jan 22
🎯Learn to Build websites in 30 Days.

Thread: 🧵
Here's what you will get:

✅ 24 * 7 Doubt Support
✅ Build 20+ Projects
✅ Daily Assignments
✅ 30 Codepen Projects to practice.
✅ Next 30 days Plan of Action
✅ 100+ Quiz Ques.
✅ Content Creation Guide
✅ eBooks worth $20 for Free.
50% OFF - Only 25 Seats left.
Read 14 tweets
Jan 22
A quick glance at "CSS Flexbox Model (Flex Container)"

Open this MEGA-Thread🧵 to learn more about "CSS Flexbox"👇🏻 Image
🔶 CSS Flexbox Model (Flex Container)

To start using the Flexbox model, you need to first define a flex container. Image
Example👇 Image
Read 19 tweets
Jan 21
In today's Thread 🧵 we will learn about

"CSS Multiple Columns" Image
🔶 CSS Multiple Columns

The CSS multi-column layout allows easy definition of multiple columns of text - just like in newspapers: Image
🔶 CSS Create Multiple Columns

The `column-count` property specifies the number of columns an element should be divided into. Image
Read 6 tweets
Jan 20
⛳Learn to Build websites in 30 Days.

Thread: 🧵
Here's what you will get:

✅ 24 * 7 Doubt Support
✅ Build 20+ Projects
✅ Daily Assignments
✅ 30 Codepen Projects to practice.
✅ Next 30 days Plan of Action
✅ 100+ Quiz Ques.
✅ Content Creation Guide
✅ eBooks worth $20 for Free.
50% OFF - Only 25 Seats left.
Read 14 tweets
Jan 19
A quick glance at "CSS Advance Selector "

Thread🧵
🔶Element Selector

The element selector selects HTML elements based on the element name.
🔶 ID Selector

👉 The id of an element is unique within a page, so the id selector is used to select one unique element!

👉 To select an element with a specific id, write a hash (#) character, followed by the id of the element.
Read 14 tweets
Jan 18
⛳Learn to Build websites in 30 Days.

Thread: 🧵
Here's what you will get:

✅ 24 * 7 Doubt Support
✅ Build 20+ Projects
✅ Daily Assignments
✅ 30 Codepen Projects to practice.
✅ Next 30 days Plan of Action
✅ 100+ Quiz Ques.
✅ Content Creation Guide
✅ eBooks worth $20 for Free.
50% OFF - Only 25 Seats left.
Read 14 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us on Twitter!

:(