Style alignContent Property
Style alignContent Property
The alignContent property is used for aligning the flexible container items. It happens when the items do not use all available space vertically i.e, cross-axis. For aligning items horizontally used the justifyContent property because it set items horizontally. For this property to work, multiple lines must be present.
Syntax:-
Its syntax is:- object.style.alignContent OR object.style.alignContent = stretch|center|flex-start|flex-end|space-between|space-around|initial|inherit
Return:-
Its return is:- a string having align-content property of an element
Further Explanation:-
Value | Description |
---|---|
stretch | Items are stretched to fit container |
center | Items are positioned at center of container |
flex-start | Items are positioned at beginning of container |
flex-end | Items are positioned at end of container |
space-between | Items are positioned with space between lines |
space-around | Items are positioned with space before, between, and after lines |
initial | Sets property to its default value. |
inherit | Inherits property from its parent element. |