A drag-and-drop library that finally works on React Native ✨ Powerful, performant, and built for the modern React Native developer
> /plugin marketplace add entropyconquers/react-native-reanimated-dnd> /plugin install reanimated-dnd@reanimated-dnd-skills
Repo: entropyconquers/react-native-reanimated-dnd
What's inside
https://github.com/user-attachments/assets/023c0a9c-194a-45a9-bb88-ac8f16f5ffd5
A drag-and-drop library that finally works on React Native ✨
Powerful, performant, and built for the modern React Native developer
After countless attempts with drag-and-drop solutions that don't work or are simply outdated, this is something that finally works. And it is not just another DnD library, but a complete ecosystem built from the ground up for React Native, offering a best-in-class developer experience and production-ready performance.
Highly feature-packed with every interaction pattern you'll ever need, yet simple enough to get started in minutes. Built for developers who demand both power and simplicity.
See it in action! A comprehensive example app with 18 interactive demos showcasing every feature and use case.
📱 Scan & Play
Scan with Expo Go to try the demo instantly
🚀 Quick Start
Or browse the code: 📂 View Example App →
Comprehensive guides, API reference, and interactive examples
The example app includes:
Vertical list reordering with drag handles
https://github.com/user-attachments/assets/6493c05f-571c-416d-b81d-90bee98738b4
Features: Auto-scrolling • Drag handles • Smooth transitions
Reorderable horizontal scrolling list
https://github.com/user-attachments/assets/909c687e-146d-4233-a6e9-4bc3e7b69a35
Features: Horizontal scroll • Handle & full item modes
2D grid reordering with insert & swap
https://github.com/user-attachments/assets/9647af01-098c-485f-92ba-cfc39d1bba0c
Features: Grid layout • Insert & swap modes
Sortable list with variable item heights
https://github.com/user-attachments/assets/b53078ca-51ab-4675-9389-e8fe69492370
Features: Variable heights • Expand/collapse • Auto-scroll
Drag items to drop zones
https://github.com/user-attachments/assets/05859d25-6749-41b7-ae7e-cad5f864a268
Features: Drop zones • Pre-drag delay • Visual feedback
Dedicated regions for drag control
https://github.com/user-attachments/assets/f8be7bea-0f24-4446-83be-06ede43fa02a
Features: Full handle • Bar handle • Header handle
Visual hover effects on drop zones
https://github.com/user-attachments/assets/d4124110-6eb7-4a15-8f97-3e58b392d62e
Feedback: Pulse effect • Glow effect • Hover states
Precise drop positioning with offsets
https://github.com/user-attachments/assets/07fd39d0-a0d8-471c-86be-b73d70027163
Features: 9-point alignment • X/Y offset controls
Constrain movement within boundaries
https://github.com/user-attachments/assets/ce43a226-ec42-49c1-b528-df6599d294e1
Constraints: Container bounds • Axis-locked • Custom limits
Center, intersect & contain algorithms
https://github.com/user-attachments/assets/1ac1860a-acc1-469a-ae3e-644a22393b86
Algorithms: Center • Intersect • Contain
Track items across multiple zones
https://github.com/user-attachments/assets/e4effc88-7161-4c5c-af6e-c06152cfbd09
Features: Multi-zone tracking • Real-time mapping
State lifecycle tracking & callbacks
https://github.com/user-attachments/assets/bceb9e7c-8f29-4630-81b0-945a7bcf29c5
States: Idle • Dragging • Dropped
npm install react-native-reanimated-dnd
npm install react-native-reanimated react-native-gesture-handler react-native-worklets
Follow the setup guides:
Make sure your Babel config uses "react-native-worklets/plugin" as the last plugin and that your app is running on the New Architecture, which is required by Reanimated 4.
All items in your data array MUST have an id property of type string:
interface YourDataType {
id: string; // Required!
// ... your other properties
}
This is essential for the library to track items during reordering.
Example:
// ✅ Good - Each item has a unique string id
const tasks = [
{ id: "1", title: "Learn React Native", completed: false },
{ id: "2", title: "Build an app", completed: false },
{ id: "3", title: "Deploy to store", completed: true },
];
// ❌ Bad - Missing id properties
const badTasks = [{ title: "Task 1" }, { title: "Task 2" }];
// ❌ Bad - Non-string ids
const badTasksWithNumbers = [
{ id: 1, title: "Task 1" },
{ id: 2, title: "Task 2" },
];
The library includes runtime validation in development mode that will warn you if items are missing valid ID properties.
IMPORTANT: Sortable components maintain their own internal state for optimal performance and animation consistency.
onMove callbackssetItems(), setTasks(), or similar functions during drag operationsonMove for logging, analytics, or side effects onlyonDrop with allPositions parameter for read-only position trackingProgrammatic list operations (add, update, delete, reorder items) that work correctly with internal state management will be added in upcoming releases. This will provide safe methods to modify sortable lists externally.
import { GestureHandlerRootView } from "react-native-gesture-handler";
import { Draggable, Droppable, DropProvider } from "react-native-reanimated-dnd";
export default function App() {
return (
<GestureHandlerRootView style={{ flex: 1 }}>
<DropProvider>
<Droppable onDrop={(data) => console.log("Dropped:", data)}>
<View style={styles.dropZone}>
<Text>Drop here</Text>
</View>
</Droppable>
<Draggable data={{ id: "1", title: "Drag me!" }}>
<View style={styles.item}>
<Text>Drag me around!</Text>
</View>
</Draggable>
</DropProvider>
</GestureHandlerRootView>
);
}
import { Sortable, SortableItem, SortableRenderItemProps } from "react-native-reanimated-dnd";
const tasks = [
{ id: "1", title: "Learn React Native" },
{ id: "2", title: "Build an app" },
{ id: "3", title: "Deploy to store" },
];
function TaskList() {
const renderItem = useCallback((props: SortableRenderItemProps<typeof tasks[0]>) => {
const { item, id, ...rest } = props;
return (
<SortableItem key={id} id={id} data={item} {...rest}>
<View style={styles.task}>
<Text>{item.title}</Text>
<SortableItem.Handle>
<Text>⋮⋮</Text>
</SortableItem.Handle>
</View>
</SortableItem>
);
}, []);
return <Sortable data={tasks} renderItem={renderItem} itemHeight={60} />;
}
import { SortableGrid, SortableGridItem } from "react-native-reanimated-dnd";
const apps = [
{ id: "1", label: "Photos" },
{ id: "2", label: "Music" },
{ id: "3", label: "Settings" },
{ id: "4", label: "Mail" },
];
function AppGrid() {
const renderItem = useCallback((props) => {
const { item, id, ...rest } = props;
return (
<SortableGridItem key={id} id={id} {...rest}>
<View style={styles.gridItem}>
<Text>{item.label}</Text>
</View>
</SortableGridItem>
);
}, []);
return (
<SortableGrid
data={apps}
renderItem={renderItem}
dimensions={{ columns: 4, itemWidth: 80, itemHeight: 80, rowGap: 12, columnGap: 12 }}
/>
);
}
More examples: Quick Start Guide · Sortable Lists · Sortable Grids · All Examples
Visit reanimated-dnd-docs.vercel.app for the full documentation:
git clone https://github.com/entropyconquers/react-native-reanimated-dnd.git
cd react-native-reanimated-dnd
npm install
# iOS
npm run start --workspace example-app
# then press 'i' for iOS or 'a' for Android
# Or run directly:
npx expo run:ios --cwd example-app
npx expo run:android --cwd example-app
Note: Reanimated 4 requires the New Architecture, so you must use a development build (npx expo run:ios / npx expo run:android), not Expo Go.
The example app includes all 18 interactive examples showcasing every feature of the library.
I am constantly working to improve React Native Reanimated DnD. Here's what's coming next:
Reanimated 4 + Worklets Migration
scheduleOnRN/scheduleOnUI for better worklet-to-JS communicationpreDragDelay prop for distinguishing taps from dragsFocus: Enhanced Functionality & New Features
🐛 Bug Fixes & Issues Resolution
🪆 Nested Sortable Lists
📋 Kanban Board Support
Vote on features you'd like to see by raising an issue.
Have an idea? Open a feature request and let me know!
Speed up development with the official agent skill. It teaches AI coding agents (Claude Code, Codex, Cursor, Gemini CLI, Copilot, and 30+ more) the full API so they generate correct code — no hallucinated props.
# Install via npx skills (auto-detects your agents)
npx skills add entropyconquers/react-native-reanimated-dnd
# Or install globally
npx skills add entropyconquers/react-native-reanimated-dnd -g
Once installed, just describe what you want:
"Add a sortable list where I can reorder items by dragging"
"Create a drag and drop interface with drop zones"
"Make a reorderable 3-column grid"
Your agent will generate complete, working implementations with correct imports, props, and state management.
The skill ships in both .claude/skills/ (Claude Code) and .agents/skills/ (Codex, Cursor, Gemini CLI, Copilot, and others) for universal agent compatibility. See the AI Integration Skill docs for all installation options and the full agent compatibility table.
Contributions are always welcome! We believe in building this library together with the community.
Ways to contribute:
Please see our Contributing Guide for detailed information on:
MIT © Vishesh Raheja
Made with ❤️ for the React Native community
.agents/
skills/
reanimated-dnd/
SKILL.md
.claude/
.claude-plugin/
marketplace.json
plugins/
reanimated-dnd/
.claude-plugin/
plugin.json
skills/
reanimated-dnd/
SKILL.md
scheduled_tasks.lock
skills/
reanimated-dnd/
SKILL.md
.github/
workflows/
docs-deploy.yml
.gitignore
.npmignore
.prettierignore
.prettierrc
app.json
components/
Draggable.tsx
Droppable.tsx
Sortable.tsx
SortableGrid.tsx
SortableGridItem.tsx
SortableItem.tsx
sortableUtils.ts
context/
DropContext.tsx
CONTRIBUTING.md
DEVELOPMENT.md
documentation/
images/
demos/
active-drop-styles.jpg
alignment-offset.jpg
basic-drag-drop.jpg
bounded-dragging.jpg
collision-detection.jpg
drag-handles.jpg
drag-state.jpg
dropped-items-map.jpg
dynamic-heights.jpg
grid-sortable.jpg
horizontal-sortable.jpg
sortable-music-queue.jpg
expo-qr-code.png
launch-video-thumbnail.jpg
reanimated-dnd.gif
videos/
active-drop-styles.mp4
bounded-dragging.mp4
collision-detection.mp4
drag-handles.mp4
web-docs/
.env.example
.gitignore
app/
(home)/
layout.tsx
page.tsx
api/
chat/
route.ts
search/
route.ts
docs/
[[...slug]]/
page.tsx
layout.tsx
global.css
layout.tsx
llms-full.txt/
route.ts
llms.mdx/
docs/
[[...slug]]/
route.ts
llms.txt/
route.ts
cli.json
components/
ai/
page-actions.tsx
search.tsx
markdown.tsx
mdx.tsx
ui/
button.tsx
popover.tsx
docs/
api/
components/
draggable.md
droppable.md
meta.json
sortable-grid-item.md
sortable-grid.md
sortable-item.md
sortable.md
context/
DragDropContext.md
DropProvider.md
meta.json
hooks/
meta.json
useDraggable.md
useDroppable.md
useGridSortable.md
useGridSortableList.md
useHorizontalSortable.md
useHorizontalSortableList.md
useSortable.md
useSortableList.md
meta.json
overview.md
types/
context-types.md
draggable-types.md
droppable-types.md
enums.md
grid-types.md
meta.json
sortable-types.md
utilities/
animation-functions.md
collision-algorithms.md
helper-functions.md
meta.json
components/
draggable.md
droppable.md
meta.json
sortable-item.md
sortable.md
context/
DragDropContext.md
DropProvider.md
meta.json
examples/
axis-constraints.mdx
basic-drag-drop.mdx
bounded-dragging.mdx
capacity-limits.mdx
collision-detection.mdx
custom-animations.mdx
drag-handles.mdx
drop-zones.mdx
horizontal-sortable.mdx
meta.json
sortable-lists.mdx
visual-feedback.mdx
getting-started/
ai-skill.md
basic-concepts.md
installation.md
meta.json
quick-start.md
setup-provider.md
guides/
accessibility.md
animations.md
collision-algorithms.md
constraints-bounds.md
meta.json
performance.md
troubleshooting.md
hooks/
meta.json
useDraggable.md
useDroppable.md
useHorizontalSortable.md
useHorizontalSortableList.md
useSortable.md
useSortableList.md
intro.md
meta.json
images/
docusaurus-social-card.jpg
example-app.svg
favicon.ico
logo-dark.svg
logo.svg
lib/
cn.ts
get-llm-text.ts
layout.shared.tsx
source.ts
next-env.d.ts
next.config.mjs
package-lock.json
package.json
postcss.config.mjs
public/
images/
docusaurus-social-card.jpg
example-app.svg
favicon.ico
logo-dark.svg
logo.svg
source.config.ts
tsconfig.json
example-app/
.gitignore
.prettierignore
.prettierrc
app.json
App.tsx
assets/
adaptive-icon.png
favicon.png
fonts/
SF-Pro-Display-Bold.otf
SF-Pro-Display-Medium.otf
SF-Pro-Display-Regular.otf
SF-Pro-Display-Semibold.otf
SF-Pro-Text-Bold.otf
SF-Pro-Text-Medium.otf
SF-Pro-Text-Regular.otf
SF-Pro-Text-Semibold.otf
icon.png
icons/
app-icon-1.png
app-icon-10.png
app-icon-11.png
app-icon-2.png
app-icon-3.png
app-icon-4.png
app-icon-5.png
app-icon-6.png
app-icon-7.png
app-icon-8.png
app-icon-9.png
app-icon.png
ios-wallpaper.jpg
splash-icon.png
babel.config.js
components/
AnimatedSplashScreen.tsx
BasicDraggable.tsx
BottomSheet.tsx
BottomSheetOption.tsx
CustomDraggable.tsx
ExampleHeader.tsx
examples/
ActiveStylesExample.tsx
AlignmentOffsetExample.tsx
AnimationExample.tsx
BasicDragDropExample.tsx
BoundedDraggingExample.tsx
BoundedYAxisExample.tsx
CapacityExample.tsx
CollisionDetectionExample.tsx
CustomDraggableExample.tsx
DragHandlesExample.tsx
DragStateExample.tsx
DroppedItemsMapExample.tsx
DynamicHeightExample.tsx
index.ts
XAxisConstrainedExample.tsx
YAxisConstrainedExample.tsx
ExamplesNavigationPage.tsx
Footer.tsx
GridSortableExample.tsx
HorizontalSortableExample.tsx
SortableExample.tsx
SortableHookExample.tsx
toast/
context.ts
hooks.ts
index.ts
toast-provider.tsx
toast.tsx
e2e-tests/
flows/
dynamic-height-flow-android.yaml
eas.json
index.ts
maestro/
dynamic-height-drag-test.sh
dynamic-height-test.yaml
metro.config.js
navigation/
AppNavigator.tsx
package.json
README.md
theme.ts
tsconfig.json
hooks/
index.ts
safeMeasure.ts
useDraggable.ts
useDroppable.ts
useGridSortable.ts
useGridSortableList.ts
useHorizontalSortable.ts
useHorizontalSortableList.ts
useSortable.ts
useSortableList.ts
index.ts
LICENSE
package-lock.json
package.json
README.md
scripts/
build.js
skills/
reanimated-dnd/
SKILL.md
tsconfig.json
types/
context.ts
draggable.ts
droppable.ts
grid.ts
index.d.ts
index.ts
sortable.ts
utils/
gridCalculations.tsFAQ
react-native-reanimated-dnd is a Claude Code plugin with 2 hand-picked skills for development work, indexed on Flowy. Install it with the command on its page. It includes reanimated-dnd, reanimated-dnd. Its skills do not fire on their own yet. Request auto-invocation to have Flowy route them as you prompt. Free and open source.