Skip to content

Commit 2e96f2b

Browse files
author
Claudéric Demers
authored
Merge pull request clauderic#53 from bradwestfall/patch-1
Update README.md to include a Common Pitfalls section
2 parents 5ceb45d + 2b43c5d commit 2e96f2b

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,13 @@ Asking for help
134134
----------------
135135
Please do not use the issue tracker for personal support requests. Instead, use [Gitter](https://gitter.im/clauderic/react-sortable-hoc) or StackOverflow.
136136

137+
Common Pitfalls
138+
---------------
139+
140+
### CSS messing up on drag?
141+
142+
Upon sorting, `react-sortable-hoc` creates a clone of the element you are sorting (the _sortable-helper_) and appends it to the end of the `<body>` tag. The original element will still be in-place to preserve its position in the DOM until the end of the drag (with inline-styling to make it invisible). If the _sortable-helper_ gets messed up from a CSS standpoint, consider that maybe your selectors to the draggable item are dependent on a parent element which isn't present anymore (again, since the _sortable-helper_ is at the end of the `<body>`).
143+
137144
Contributions
138145
------------
139146
Yes please! Feature requests / pull requests are welcome.

0 commit comments

Comments
 (0)