Skip to content

sergeymild/react-native-pinch-zoom

Repository files navigation

react-native-pinch-zoom

About the project

Replicate easily the Instagram zooming feature for React Native

Example

Installation

"react-native-pinch-zoom": "sergeymild/react-native-pinch-zoom#0.3.7"

Usage

import { PinchZoomView } from "react-native-pinch-zoom";

// ...
// disableScrollViewOnPinch - prevent scrollView handle scroll events on pinch zoom (only on IOS)
// onDoubleTap - callback which will be called on double tap
// onTap - callback which will be called on tap
// disabledPinchZoom - togglePinchZoom

<PinchZoomView disableScrollViewOnPinch>
  <Video
    resizeMode={'cover'}
    muted
    source={{
      uri: 'http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4',
    }}
    style={{ width: '100%', height: '100%' }}
  />
</PinchZoomView>

Contributing]

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT


Made with create-react-native-library