Skip to content

Commit

Permalink
Update files/en-us/web/css/css_flexible_box_layout/basic_concepts_of_…
Browse files Browse the repository at this point in the history
…flexbox/index.md

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
OnkarRuikar and github-actions[bot] authored Jan 8, 2025
1 parent d0982ef commit 60cac0a
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ Using `flex: auto` is the same as using `flex: 1 1 auto`; this is similar to `fl

Using `flex: none` will create fully inflexible flex items. It is as if you wrote `flex: 0 0 auto`. The items cannot grow or shrink and will be laid out using flexbox with a `flex-basis` of `auto`.

The shorthand you often see in tutorials is `flex: 1` or `flex: 2` and so on. This is the same as writing `flex: 1 1 0` or `flex: 2 1 0` and so on, respectively. The items get minimum size due to `flex-basis: 0` and then proportionally grow
The shorthand you often see in tutorials is `flex: 1` or `flex: 2` and so on. This is the same as writing `flex: 1 1 0` or `flex: 2 1 0` and so on, respectively. The items get minimum size due to `flex-basis: 0` and then proportionally grow
to fill the available space. In this case, the `flex-shrink` value of `1` is redundant because the item starts with minimum size.

Try these shorthand values in the live sample below.
Expand Down

0 comments on commit 60cac0a

Please sign in to comment.