react-native-dragable-opensource
v1.0.1
Published
a dragable component for react native
Downloads
3
Readme
React Native Custom Drag Component
A customizable React Native Dragable component that can drag your child components.
Installation
Install the package using npm or yarn:
npm i react-native-dragable-opensource
Usage
wrap your component inside Dragable to drag your component
import React from 'react';
import { SafeAreaView, TouchableOpacity, View ,Text} from 'react-native';
import Dragable from 'react-native-dragable-opensource';
const App = () => {
return (
<View style={{ flex: 1 }}>
<Dragable>
<View style={{height:100,width:100,backgroundColor:'red'}}>
<Text>hello</Text>
</View>
</Dragable>
</View>
);
};
export default App