
Security News
Frontier AI Is Now Critical Infrastructure
The Fable shutdown shows how quickly model access can become a business continuity risk for AI-dependent engineering teams.
@react-native-pure/gallery
Advanced tools
A pure JavaScript image and video gallery component for react-native apps with common gestures like pan, pinch and doubleTap, supporting both iOS and Android. Support custom item.
$ npm i @react-native-pure/gallery --save
Quite easy to use:
import GalleryView from "@react-native-pure/gallery"
import {GalleryFileType} from '@react-native-pure/gallery/src/types'
class Galleray extends React.Component{
data = [{
url:'http://www.bz55.com/uploads/allimg/150122/139-150122145421.jpg',
type:GalleryFileType.image
}]
render(){
return (
<GalleryViewer dataSource={this.data}/>
);
}
}
dataSource Array<GalleryData>style? anyinitIndex? (Number* 初始显示第几张图renderFooter? (index: Number) => React.ReactElement 自定义尾部renderHeader? (index: Number) => React.ReactElement 自定义头部renderItem? (data:GalleryData,index: Number) => React.ReactElement 内容页面渲染renderIndicator? (data:GalleryData,index: Number) => React.ReactElement 是否显示加载动画onChange? (index:number)=>void 当内容切换时触发maxScale? Number最大缩放比例minScale? (Number最小缩放比例onPress? (index: Number) =>void单击onDoubleClick? (index: Number) =>void 双击enableDoubleClickZoom? Boolean是否支持双击,默认支持onResponderGrant? ((event,gestureState)=>void 手势开始onResponderMove? ((event,gestureState)=>void 手势移动onResponderEnd? ((event,gestureState)=>void 手势结束url String 图片/视频url地址type ** $Values<typeof GalleryFileType>** 数据源类型coverImageUrl String 视频封面图地址disableZoom Boolean 禁用缩放,默认false-1 other0 图片1 视频FAQs
滑动查看图片/视频,支持缩放
The npm package @react-native-pure/gallery receives a total of 12 weekly downloads. As such, @react-native-pure/gallery popularity was classified as not popular.
We found that @react-native-pure/gallery demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?

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.

Security News
The Fable shutdown shows how quickly model access can become a business continuity risk for AI-dependent engineering teams.

Security News
AI agents are pulling packages into environments no scanner is watching, creating exposure before security teams can see it.

Security News
GitHub Actions checkout now blocks risky pull_request_target checkouts by default to help prevent pwn request supply chain attacks.