Style flex Shrink Property

Style flex Shrink Property


Style flex shrink property
Browser Support
The numbers in the table specify the first browser version that fully supports the property.
 
property
 
chrome
 
firefox
 
microsoft edge
 
Opera
 
flexShrink
 
29.0 
21.0-webkit-
 
28.0
18.0-moz-
 
11.0
 
17.0
 
Syntax
flex-shrink: number|initial|inherit;
Example
Output
 
Property Values
 
Value
 
Description
 
number
 
A number specifying how much the item will shrink relative to the rest of the flexible items. Default value is 1.
 
initial
 
Sets this property to its default value.
 
inherit
 
Inherits this property from its parent element.
 
Technical Details
 
Default value:
 
1
 
Version:
 
CSS3
 
Inherited
 
no
 
Animatable
 
yes
 
JavaScript syntax:
 
object.style.flexShrink="5"