How specific CSS targets an element?


How specific CSS targets an element? 

#IDs = 100 Points
.Classes = 10 Points
<Elements> = 1 Points

<element> can be students of an institute
.class is a specific class consist of students of a subject.
#id is a person containing an id (Though we can use same id on more than one elements, but it’s more specific than classes). 

Pssst… use “!important” (Without quotes) after a rule to override anything [BUT DON’T OVERDO IT, IT’S NOT A QUICKFIX]:

p { color: red !important;} <<---- Now this one is more important

QuikCode: Create Responsive menu with Bootstrap 4 (Alpha)

Bootstrap 4 Navigation responsive

The first entry of QuikCode, where I save codes for future use and quick references.

This is the code for responsive navigation bar that is also toggleable in md (medium screens).

<nav class="navbar navbar-toggleable-md bg-info navbar-inverse">
    <div class="container">
        <button class="navbar-toggler" data-toggle="collapse" data-target="#mainNav">
            <span class="navbar-toggler-icon"></span>
        <div class="collapse navbar-collapse" id="mainNav">
            <div class="nav navbar-nav">
                <a href="#" class="nav-item nav-link active">Home</a>
                <a href="#" class="nav-item nav-link">Features</a>
                <a href="#" class="nav-item nav-link">About</a>
                <a href="#" class="nav-item nav-link">Contact</a>


Okay, now let’s describe about the classes according to their order in the code:

Continue reading