Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,26 +12,26 @@ import withScrolling from 'react-dnd-scrollzone';
import DragItem from './DragItem';
import './App.css';

const ScrollingComponent = withScrolling('div');
const ScrollZone = withScrolling('div');

const ITEMS = [1,2,3,4,5,6,7,8,9,10];

export default class App extends Component {
render() {
return (
<DragDropContextProvider backend={HTML5Backend}>
<ScrollingComponent className="App">
<ScrollZone className="App">
{ITEMS.map(n => (
<DragItem key={n} label={`Item ${n}`} />
))}
</ScrollingComponent>
</ScrollZone>
</DragDropContextProvider>
);
}
}
```

Note: You should replace the original `div` you would like to make scrollable with the `ScrollingComponent`.
Note: You should replace the original `div` you would like to make scrollable with the `ScrollZone`.

### Easing Example

Expand Down Expand Up @@ -69,20 +69,20 @@ function vStrength(box, point) {
export default App(props) {
return (
<DragDropContextProvider backend={HTML5Backend}>
<ScrollingComponent
<ScrollZone
className="App"
verticalStrength={vStrength}
horizontalStrength={hStrength} >

{ITEMS.map(n => (
<DragItem key={n} label={`Item ${n}`} />
))}
</ScrollingComponent>
</ScrollZone>
</DragDropContextProvider>
);
}
```
Note: You should replace the original `div` you would like to make scrollable with the `ScrollingComponent`.
Note: You should replace the original `div` you would like to make scrollable with the `ScrollZone`.

### Virtualized Example

Expand Down