Skip to content

Latest commit

 

History

History
29 lines (21 loc) · 741 Bytes

File metadata and controls

29 lines (21 loc) · 741 Bytes

react-native-app-helpers/createFixedHeightComponent

Creates a React component which has a fixed height.

Usage

import { createFixedHeightComponent } from "react-native-app-helpers";

const ExampleComponent = createFixedHeightComponent(243);

const ExampleScreen = () => (
  <ExampleComponent width="fillsContainer">
    <Text>This is 243 wide and fills its container horizontally.</Text>
  </ExampleComponent>
);
import { createFixedHeightComponent } from "react-native-app-helpers";

const ExampleComponent = createFixedHeightComponent(243);

const ExampleScreen = () => (
  <ExampleComponent width="fitsContent">
    <Text>This is 243 wide and fits its content horizontally.</Text>
  </ExampleComponent>
);