Home > database >  What is the difference between width, min-width, and max-width
What is the difference between width, min-width, and max-width

Time:12-06

I am begineer in css so i have much issue between understanding how to use width, min width, and max width to create responsive layouts.

CodePudding user response:

The main difference between Max width and Min Width is that maximum width indicates the max-width of an element or image when rendered on the screen of a browser. On the other hand, min-width represents the minimum width of an element or image when rendered on the screen of a browser.

CodePudding user response:

"Max-width" sets the maximum size an element can stretch to and "Min-width" sets the minimum size an element can be clipped to. "Width" property basically sets the original / preferred width an element should be horizontally. For more : https://www.w3schools.com/cssref/pr_dim_width.php

  • Related