Skip to content

css border box #10

Merged
merged 1 commit into from
Apr 16, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions 03 - CSS/css-border-box.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<h1>What does this CSS propoerty do?</h1>

* {
box-sizing: border-box;
}

Essentially, this property makes its so that the padding and border of an HTML element are included in the width and height. For example, if two divs have the same width defined in the CSS, the border-box property would make it so they are both the same width even if they have different sized borders/padding.

The example above applies it to everything in the HTML.