CSS Output Prediction Easy +10 XP
Box Model
What is the total rendered width of this element?
CSSRead-only
.box {
width: 200px;
padding: 10px;
border: 5px solid black;
box-sizing: content-box;
}What is the output?
Show answer and explanation
Answer: 230px
With content-box: total width = width + padding*2 + border*2 = 200 + 20 + 10 = 230px.
Hint: content-box adds padding and border on top.
What this challenge tests
Output Prediction in CSS: box-model, sizing.