Flex direction: row-reverse in react-native
Asked Answered
L

2

6

How can i reproduce flex-direction: row-reverse in React-Native? When in element' style i'm doing:

 flexDirection: 'row-reverse'

i'm getting error:

Invalid prop flexDirection of value row-reverse supplied to StyleSheet

UPDATE: They just added it in version 0.29.0 :)

Lag answered 15/7, 2016 at 22:54 Comment(0)
C
12

UPDATE

As of v29, React Native provides support for reverse flex directions in Android and iOS. https://github.com/facebook/react-native/releases/tag/v0.29.0


ORIGINAL ANSWER

There is no row-reverse or column-reverse in react-native.

See this table of supported attributes:

enter image description here

https://github.com/facebook/css-layout

Cassandracassandre answered 15/7, 2016 at 23:7 Comment(0)
T
0

You can use flexDirection property and give it a value 'row-reverse' with new version.

Sample code:

flexDirection: 'row-reverse'

Proof: enter image description here

Tersanctus answered 1/8, 2023 at 8:57 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.