MatiPl01/react-native-sortables
MatiPl01/react-native-sortables has 978 GitHub stars and 29 forks. GitHot measured 0 stars in 24 hours and -1 in 7 days. Last checked 2026-11-22 20:37 UTC. Last push 2026-11-10.
What you can do
- Grid and Flex layout options
- Support for items with different dimensions
- Built with react-native-reanimated and react-native-gesture-handler
- Supports both Old and New Architecture
์ธก์ ๋ ์คํ ์ฆ๊ฐ
- in 24h
- 0
- in 7 days
- -1
- in 15 days
- ๊ธฐ๋ก ์์ง ์ค
- in 1 month
- ๊ธฐ๋ก ์์ง ์ค
์๋ก ๊ฒน์น๋ ๊ธฐ๊ฐ์ ์์ฆ๊ฐ๋์ด๋ฉฐ ์ผ๋ณ ํฉ๊ณ๊ฐ ์๋๋๋ค. ์ธก์ ๊ฐ์ด ์์ผ๋ฉด ๋น์ ๋ก๋๋ค. ์คํ๋ ๊ด์ฌ๋๋ฅผ ๋ํ๋ด๋ฉฐ ํ์ง์ ๋ณด์ฅํ์ง ์์ต๋๋ค.
์๊ฐ
๐ Powerful Sortable Components for Flexible Content Reordering in React Native
์น ๋ฐ ์ฑREADME.md
Original
React Native Sortables
Powerful Sortable Components for Flexible Content Reordering in React Native
Documentation | Real-World Examples | Simple Usage Examples | Contributing
Overview
React Native Sortables is a powerful and easy-to-use library that brings smooth, intuitive content reordering to React Native. It provides specialized components whose children can be dynamically reordered through natural dragging gestures.
Key Features
๐ฏ Flexible Layouts
- Grid and Flex layout options
- Support for items with different dimensions
๐ Performance & Reliability
- Built with react-native-reanimated and react-native-gesture-handler
- Supports both Old and New Architecture
- Type safe with TypeScript
- Expo compatible
โจ Rich Interactions
- Auto-scrolling beyond screen bounds
- Customizable layout animations for items addition and removal
- Built-in haptic feedback integration (optional) via react-native-pulsar, expo-haptics or react-native-haptic-feedback
- Different reordering strategies (insertion, swapping)
๐ก Developer Experience
- Simple API with powerful customization
- Minimal setup required
โ More features
Installation
- npm
npm install react-native-sortables
- yarn
yarn add react-native-sortables
Dependencies
This library is built with:
- react-native-reanimated (version 3.x, 4.x)
- react-native-gesture-handler (version 2.x, 3.x)
Make sure to follow their installation instructions for your project.
[!NOTE] On iOS + New Architecture, gesture-handler 2.x can leave a dragged item "stuck" after its screen is detached and re-attached (e.g. bottom tabs with
detachInactiveScreens={false}) - see #349. gesture-handler 3 fixes this, and the library uses it automatically when installed (v3 requires the New Architecture). The Old Architecture is unaffected, so 2.x is the right choice there.
Quick Start
import { useCallback } from 'react';
import { Text, View, StyleSheet } from 'react-native';
import type { SortableGridRenderItem } from 'react-native-sortables';
import Sortable from 'react-native-sortables';
const DATA = Array.from({ length: 12 }, (_, index) => `Item ${index + 1}`);
export default function Grid() {
const renderItem = useCallback<SortableGridRenderItem<string>>(
({ item }) => (
<View style={styles.card}>
<Text>{item}</Text>
</View>
),
[]
);
return (
<Sortable.Grid
columns={3}
data={DATA}
renderItem={renderItem}
rowGap={10}
columnGap={10}
/>
);
}
const styles = StyleSheet.create({
card: {
backgroundColor: '#36877F',
height: 100,
borderRadius: 10,
alignItems: 'center',
justifyContent: 'center'
}
});
For detailed usage and examples, check out the Documentation.
Local Library Development
Clone and setup:
git clone https://github.com/MatiPl01/react-native-sortables.git cd react-native-sortables yarn yarn pod # iOS onlyStart an example app:
cd example/fabric # or any other example yarn startAvailable example apps:
fabric- React Native Fabric examplepaper- React Native Paper exampleexpo- Expo exampleweb- Web example
You can also run commands from the project root using the
yarn example:<name> <command>syntax, e.g.:yarn example:fabric start yarn example:paper android yarn example:expo iosBuild and run:
- iOS:
yarn iosor build in Xcode - Android:
yarn androidor build in Android Studio
- iOS:
Contributing
Contributions are welcome! Please read the Contributing Guide for details.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Support
- ๐ Star this repo to show support
- ๐ Report bugs by creating an issue
- ๐ก Request features in discussions open a discussion
๊ด๋ จ ํ๋ก์ ํธ ์ดํด๋ณด๊ธฐ
๋ถ๋ฌ์ค๋ ์คโฆ