Prop Style Flexwrap
# Style flexWrap Property
[ Style Object](#)
## Example
Make flexible items wrap to a new line when necessary:
document.getElementById("main".style.flexWrap="wrap";
[Try it Β»](#)
* * *
## Definition and Usage
The flexWrap property specifies whether the flexible items should wrap or not.
**Note:** If the element is not a flexible item, the flexWrap property has no effect.
* * *
## Browser Support

Firefox, Opera, and Chrome support the flexWrap property.
* * *
## Syntax
Return the flexWrap property:
_object_.style.flexWrap
Set the flexWrap property:
_object_.style.flexWrap="nowrap|wrap|wrap-reverse|initial|inherit"
## Property Values
| Value | Description |
| --- | --- |
| nowrap | Default value. Specifies that the flexible items will not wrap. |
| wrap | Specifies that the flexible items will wrap if necessary. |
| wrap-reverse | Specifies that the flexible items will wrap if necessary, but in reverse order. |
| initial | Sets this property to its default value. Read about _initial_. |
| inherit | Inherits this property from its parent element. Read about _inherit_. |
## Technical Details
| Default value: | nowrap |
| --- | --- |
| Return value: | A string, representing the flex-wrap property of an element. |
| CSS Version | CSS3 |
* * *
## Related Articles
CSS Reference: (#)
HTML DOM STYLE Reference: (#)
HTML DOM STYLE Reference: (#)
HTML DOM STYLE Reference: (#)
HTML DOM STYLE Reference: (#)
HTML DOM STYLE Reference: (#)
HTML DOM STYLE Reference: (#)
* * Style Object](#)
YouTip