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

react-native-swipeable-view

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-native-swipeable-view

iOS-style swipeout buttons behind component

  • 1.1.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
25
decreased by-32.43%
Maintainers
1
Weekly downloads
 
Created
Source

react-native-swipeable-view

This library allow you to create swipeable component, by exemple for a row in a list view, or anywhere you want. The code is based on the experimental SwipeableListView of react-native.

swipe

Installation

npm install --save react-native-swipeable-view

Usage example

import SwipeableView from 'react-native-swipeable-view';

// Buttons
var btnsArray = [
  {
    text: 'Button',
  },
];

// SwipeableView component
<SwipeableView btnsArray={ btnsArray }>
  <View>
    <Text>Swipe me left</Text>
  </View>
</SwipeableView>

Props

PropTypeOptionalDefaultDescription
isOpen        bool  YesfalseSwipeout is open or not
autoClose      bool  Yes    false  Auto-Close on button press
btnsArrayarrayNo[]Swipe buttons array
onOpenfuncYesCallback when swipe is opened
onClosefuncYesCallback when swipe is closed
onSwipeStart  func  Yes      Callback when swipe start
onSwipeEnd  func  Yes      Callback when swipe end
shouldBounceOnMountboolYesfalseBounce component on mount
swipeThresholdnumberYes30The minimum swipe distance required before fully animating the swipe
isRTLboolYesfalseTrue/false if the current language is right to left
Button props
PropTypeOptionalDefaultDescription
props          objectYes             Pass custom props to button component
component      stringYes    null  Pass custom component to button
onPressfuncYesnullFunction executed onPress
textstringYes'Click Me'Text
typestringYes'default'Default, primary, secondary

To Do

If you have any amelioration:

https://github.com/magrinj/react-native-swipeable-view/issues

Keywords

FAQs

Package last updated on 24 Oct 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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc