1.0.5 • Published 1 year ago

rn-shared-components v1.0.5

Weekly downloads
-
License
ISC
Repository
github
Last release
1 year ago

Shared components for React Native

Installation

npm install --save rn-shared-components

or

yarn add rn-shared-components

Components

Box

This component is a simple wrapper for View component. It has the same props as View component and some additional props listed in Box Props

import { Box } from "rn-shared-components";

const App = () => (
  <Box mFull mCenter mMarginTopLarge>
    <Text>Hello World</Text>
  </Box>
);

TouchableOpacity

This component is a simple wrapper for TouchableOpacity component. It has the same props as TouchableOpacity component and some additional props listed in Box Props

import { TouchableOpacity } from "rn-shared-components";

const App = () => (
  <TouchableOpacity mFull mCenter mMarginTopLarge>
    <Text>Hello World</Text>
  </TouchableOpacity>
);

Text

This component is a simple wrapper for Text component. It has the same props as Text component and some additional props listed in Text Props

import { Text } from "rn-shared-components";

const App = () => (
  <Text mFull mAlignCenter mMarginTopLarge>
    Hello World
  </Text>
);

To add custom props

Checkout the sample at Custom Props

1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago