New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More

react-native-thumbnail-grid

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-native-thumbnail-grid

The photo thumbnail grid

  • 0.1.5
  • npm
  • Socket score

Version published
Weekly downloads
86
increased by258.33%
Maintainers
1
Weekly downloads
 
Created

React Native Photo Grid

Code:

const images = [
  'https://cdn.pixabay.com/photo/2017/06/09/09/39/adler-2386314_960_720.jpg',
  'https://cdn.pixabay.com/photo/2017/06/02/18/24/fruit-2367029_960_720.jpg',
  'https://cdn.pixabay.com/photo/2016/08/12/22/34/apple-1589869_960_720.jpg'
]
...
<PhotoGrid source={images} onPressImage={uri => this.showImage(uri)} />

Props

PropertyTypeDescription
sourcePropTypes.arrayArray uri of image
widthPropTypes.numberContainer width
heightPropTypes.numberContainer height
ratioPropTypes.floatSplit screen ratio
stylePropTypes.objectContainer styles
imageStylePropTypes.objectImage styles
imagePropsPropTypes.objectImage props
onPressImagePropTypes.funcCallback when press image

Image props

PropertyDescription
placeholderSourceShow placeholderSource if the source can't be loaded or error.
loadingStyleStyle ActivityIndicator {size: 'small'; color: 'gray'}
isShowActivityShow ActivityIndicator loading
placeholderStyleStyle placeholder image

Keywords

FAQs

Package last updated on 20 Jul 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts