react-native-image-capinsets
v0.5.0
Published
android support for Image `capInsets`
Downloads
287
Maintainers
Readme
react-native-image-capinsets
adds support for a similar functionality as <Image capInsets={...} />
to android.
behind the scenes it will generate a NinePatchDrawable
and set as background for the android ImageView
Installation
npm i --save react-native-image-capinsets
react-native link react-native-image-capinsets
Examples
import ImageCapInset from 'react-native-image-capinsets';
<ImageCapInset
source={require('./bubble.png')}
capInsets={{ top: 8, right: 8, bottom: 8, left: 8 }}
/>