CSS outline property
An outline is a line drawn outside the element boundary.
The attributes are:
outline-widthoutline-styleoutline-coloroutline-offsetoutline
Example
.p1 {
outline-width: 5px;
outline-style: solid;
outline-color: #e40606;
border: 2px solid black;
}
Click on the "Try it Now" button to see how it works.
Sample Code
Copy each file contents and paste it to your own project and run to see the final output
Example
.p1 {
outline-width: thick;
outline-style: solid;
outline-color: #e40606;
outline-offset: 2px;
border: 2px solid black;
}
Click on the "Try it Now" button to see how it works.