Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

To adjust the width of a div within a flexbox, you should use the "flex-basis" property with a specific value. For example:

.container {
  display: flex;
}

.item {
  flex-basis: 50%; /* adjust the width to 50% */
}

You can also use the "flex-grow" and "flex-shrink" properties to adjust the width of the div based on available space and content size.