Incredible screen reader support ♿️ - we provide an amazing experience for english screen readers out of the box 📦. We also provide complete customisation control and internationalisation support for those who need it 💖
A <Droppable /> list can be a scroll container (without a scrollable parent) or be the child of a scroll container (that also does not have a scrollable parent)
Independent nested lists - a list can be a child of another list, but you cannot drag items from the parent list into a child list
react-beautiful-dnd exists to create beautiful drag and drop for lists that anyone can use - even people who cannot see. For a good overview of the history and motivations of the project you can take a look at these external resources:
There are a lot of libraries out there that allow for drag and drop interactions within React. Most notable of these is the amazing react-dnd. It does an incredible job at providing a great set of drag and drop primitives which work especially well with the wildly inconsistent html5 drag and drop feature. react-beautiful-dnd is a higher level abstraction specifically built for lists (vertical, horizontal, movement between lists, nested lists and so on). Within that subset of functionality react-beautiful-dnd offers a powerful, natural and beautiful drag and drop experience. However, it does not provide the breadth of functionality offered by react-dnd. So react-beautiful-dnd might not be for you depending on what your use case is.
🔒 Archived
This project is now archived and is deprecated on
npm. If you are still usingreact-beautiful-dnd, we have put together some resources to help you move forward. To see our ongoing work in the drag and drop problem space, head to Pragmatic drag and drop.We are so grateful to everybody who contributed in big and small ways to this project.
Cheers
react-beautiful-dnd (rbd)
Beautiful and accessible drag and drop for lists with
ReactPlay with this example if you want!
Core characteristics
Get started 👩🏫
We have created a free course on
egghead.io🥚 to help you get started withreact-beautiful-dndas quickly as possible.Currently supported feature set ✅
<table>reordering - table pattern<Draggable />@atlaskit/treepackage<Droppable />list can be a scroll container (without a scrollable parent) or be the child of a scroll container (that also does not have a scrollable parent)Motivation 🤔
react-beautiful-dndexists to create beautiful drag and drop for lists that anyone can use - even people who cannot see. For a good overview of the history and motivations of the project you can take a look at these external resources:Not for everyone ✌️
There are a lot of libraries out there that allow for drag and drop interactions within React. Most notable of these is the amazing
react-dnd. It does an incredible job at providing a great set of drag and drop primitives which work especially well with the wildly inconsistent html5 drag and drop feature.react-beautiful-dndis a higher level abstraction specifically built for lists (vertical, horizontal, movement between lists, nested lists and so on). Within that subset of functionalityreact-beautiful-dndoffers a powerful, natural and beautiful drag and drop experience. However, it does not provide the breadth of functionality offered byreact-dnd. Soreact-beautiful-dndmight not be for you depending on what your use case is.Documentation 📖
About 👋
Sensors 🔉
API 🏋️
<DragDropContext />- Wraps the part of your application you want to have drag and drop enabled for<Droppable />- An area that can be dropped into. Contains<Draggable />s<Draggable />- What can be dragged aroundresetServerContext()- Utility for server side rendering (SSR)Guides 🗺
<DragDropContext />responders -onDragStart,onDragUpdate,onDragEndandonBeforeDragStart<Draggable />sinnerRefdraggableIdanddroppableIdsdoctypeTypeScriptandflow: type information<svg>sreact-beautiful-dnd<Draggable />s during a drag (11.x behaviour) - ⚠️ AdvancedPatterns 👷
<Draggable />- Using our cloning API or your own portalSupport 👩⚕️
Read this in other languages 🌎
Creator ✍️
Alex Reardon @alexandereardon
Maintainers
Collaborators 🤝