1234567891011121314151617 |
- import React from 'react';
- import { View } from 'react-native';
- class FlexDimensionsBasics extends React.Component {
- render() {
- return (
- // Try with height: 300 instead of flex: 1
- <View style={{ flex: 1 }}>
- <View style={{ flex: 1, backgroundColor: 'powderblue' }} />
- <View style={{ flex: 2, backgroundColor: 'skyblue' }} />
- <View style={{ flex: 3, backgroundColor: 'steelblue' }} />
- </View>
- );
- }
- }
- export default FlexDimensionsBasics;
|