How to use the react-dnd/lib/DragDropContext function in react-dnd

To help you get started, we’ve selected a few react-dnd examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github zalmoxisus / social-expert / src / app / components / settings / sortable / Sortable.js View on Github external
};

const mapStateToProps = state => ({
  subs: state.subs.get('github'),
  error: state.subs.get('error')
});

const mapDispatchToProps = dispatch => ({
  fetchSubs: () => { dispatch(fetchSubs.request()); },
  reorderSubs: (fromObj, toObj) => {
    dispatch(reorderSubs('github', fromObj, toObj));
  }
});

export default connect(mapStateToProps, mapDispatchToProps)(
  DragDropContext(Touch({ enableMouseEvents: true }))(Sortable)
);