Trusted answers to developer questions
Trusted Answers to Developer Questions

Related Tags

css
css3
flex

CSS flex-direction property

Educative Answers Team

The flex-direction property specifies the direction and axis of the flex items (children elements) inside a flexible container or flexbox.

Syntax

flex-direction: row|row-reverse|column|column-reverse|initial|inherit;

Default value: row

svg viewer

Implementation

We make the container a Flexbox by setting display: flex. We then use flex-direction: column to set the axis to be vertical.

Try experimenting with different values like row, row-reverse, and column-reverse for flex-direction.

  • HTML
  • CSS

RELATED TAGS

css
css3
flex
Copyright ©2022 Educative, Inc. All rights reserved
RELATED COURSES

View all Courses

Keep Exploring